CMsgBioControl Class Reference

#include <app/msgbiocontrol.h>

Link against: MsgEditorUtils.lib

class CMsgBioControl : public CCoeControl

Inherits from

  • CMsgBioControl
    Protected Attributes
    MMsgBioControlObserver &iBioControlObserver
    TMsvId iId
    Public Member Functions
    CMsgBioControl(MMsgBioControlObserver &, CMsvSession *, TMsvId, TMsgBioMode, const RFile *)
    ~CMsgBioControl()
    IMPORT_C TBoolConfirmationQueryL(const TDesC &)
    IMPORT_C TBoolConfirmationQueryL(TInt)
    IMPORT_C TBoolIsCursorLocation(TMsgCursorLocation)
    IMPORT_C voidNotifyViewEvent(TMsgViewEvent, TInt)
    IMPORT_C TUint32OptionMenuPermissionsL()
    IMPORT_C TIntScrollL(TInt, TMsgScrollDirection)
    IMPORT_C TIntVirtualHeight()
    IMPORT_C TIntVirtualVisibleTop()
    Protected Member Functions
    IMPORT_C voidAddMenuItemL(CEikMenuPane &, TInt, TInt, TInt)
    IMPORT_C const RFile &FileHandle()
    IMPORT_C const TFileName &FileName()
    IMPORT_C TBoolIsEditor()
    IMPORT_C TBoolIsFileBased()
    IMPORT_C voidLoadResourceL(const TDesC &)
    IMPORT_C voidLoadResourceL(const TDesC &, const TDesC &)
    IMPORT_C voidLoadStandardBioResourceL()
    IMPORT_C CMsvSession &MsvSession()
    IMPORT_C TBoolNotifyEditorViewL(TMsgBioControlEventRequest, TInt)
    IMPORT_C voidSetExtension(MMsgBioControlExtension *)
    Inherited Attributes
    CCoeControl::iCoeEnv
    CCoeControl::iContext
    CCoeControl::iPosition
    CCoeControl::iSize
    Inherited Enumerations
    CCoeControl:TZoomType
    Inherited Functions
    CBase::CBase()
    CBase::Delete(CBase *)
    CBase::Extension_(TUint,TAny *&,TAny *)
    CBase::operator new(TUint)
    CBase::operator new(TUint,TAny *)
    CBase::operator new(TUint,TLeave)
    CBase::operator new(TUint,TLeave,TUint)
    CBase::operator new(TUint,TUint)
    CBase::~CBase()
    CCoeControl::AccumulatedZoom()const
    CCoeControl::ActivateGc()const
    CCoeControl::ActivateL()
    CCoeControl::BackedUpWindow()const
    CCoeControl::Background()const
    CCoeControl::CCoeControl()
    CCoeControl::CCoeControl(CCoeEnv *)
    CCoeControl::CCoeControl(const CCoeControl &)
    CCoeControl::CCoeControlArray
    CCoeControl::CapturesPointer()const
    CCoeControl::ClaimPointerGrab(TBool)
    CCoeControl::ClaimPointerGrab(TInt,TBool)
    CCoeControl::CloseWindow()
    CCoeControl::ComponentArrayExists()const
    CCoeControl::ComponentControl(TInt)const
    CCoeControl::Components()
    CCoeControl::Components()const
    CCoeControl::ConstructFromResourceL(TResourceReader &)
    CCoeControl::ControlContext()const
    CCoeControl::ControlEnv()const
    CCoeControl::CopyControlContextFrom(const CCoeControl *)
    CCoeControl::CountComponentControls()const
    CCoeControl::CreateBackedUpWindowL(RWindowTreeNode &)
    CCoeControl::CreateBackedUpWindowL(RWindowTreeNode &,TDisplayMode)
    CCoeControl::CreateWindowL()
    CCoeControl::CreateWindowL(RWindowGroup *)
    CCoeControl::CreateWindowL(RWindowTreeNode &)
    CCoeControl::CreateWindowL(const CCoeControl *)
    CCoeControl::CustomGc()const
    CCoeControl::DeactivateGc()const
    CCoeControl::DrawBackground(const TRect &)const
    CCoeControl::DrawDeferred()const
    CCoeControl::DrawForeground(const TRect &)const
    CCoeControl::DrawNow()const
    CCoeControl::DrawNow(const TRect &)const
    CCoeControl::DrawableWindow()const
    CCoeControl::EnableDragEvents()
    CCoeControl::EnableReportControlStateChange(TBool)
    CCoeControl::EnableWindowTransparency()
    CCoeControl::FindBackground()const
    CCoeControl::FindFontProvider()const
    CCoeControl::FocusChanged(TDrawNow)
    CCoeControl::GetColor(TInt,TRgb &)const
    CCoeControl::GetColorUseListL(CArrayFix< TCoeColorUse > &)const
    CCoeControl::GetGc()const
    CCoeControl::GetHelpContext(TCoeHelpContext &)const
    CCoeControl::GrabbingComponent()const
    CCoeControl::GrabbingComponent(TInt)const
    CCoeControl::HandleComponentControlsResourceChange(TInt)
    CCoeControl::HandleControlArrayEventL(CCoeControlArray::TEvent,const CCoeControlArray *,CCoeControl *,TInt)
    CCoeControl::HandlePointerBufferReadyL()
    CCoeControl::HandlePointerEventL(const TPointerEvent &)
    CCoeControl::HandleRedrawEvent(const TRect &)const
    CCoeControl::HandleResourceChange(TInt)
    CCoeControl::HasBorder()const
    CCoeControl::HitTest()const
    CCoeControl::IgnoreEventsUntilNextPointerUp()
    CCoeControl::Index(const CCoeControl *)const
    CCoeControl::InitComponentArrayL()
    CCoeControl::InputCapabilities()const
    CCoeControl::IsActivated()const
    CCoeControl::IsBackedUp()const
    CCoeControl::IsBeingDestroyed()const
    CCoeControl::IsBlank()const
    CCoeControl::IsDimmed()const
    CCoeControl::IsFocused()const
    CCoeControl::IsNonFocusing()const
    CCoeControl::IsReadyToDraw()const
    CCoeControl::IsVisible()const
    CCoeControl::LayoutManager()const
    CCoeControl::MakeVisible(TBool)
    CCoeControl::MaximumWidth()const
    CCoeControl::MinimumSize()
    CCoeControl::MopSupplyObject(TTypeUid)
    CCoeControl::NotifyFontChange(const CCoeFontProvider *)
    CCoeControl::Observer()const
    CCoeControl::OfferKeyEventL(const TKeyEvent &,TEventCode)
    CCoeControl::OverrideColorL(TInt,TRgb)
    CCoeControl::OwnsWindow()const
    CCoeControl::Parent()
    CCoeControl::Parent()const
    CCoeControl::Position()const
    CCoeControl::PositionChanged()
    CCoeControl::PositionRelativeToScreen()const
    CCoeControl::PrepareForFocusGainL()
    CCoeControl::PrepareForFocusLossL()
    CCoeControl::ProcessPointerBufferReadyL()
    CCoeControl::ProcessPointerEventL(const TPointerEvent &)
    CCoeControl::Rect()const
    CCoeControl::RecursivelyMergeInputCapabilities(TCoeInputCapabilities &)const
    CCoeControl::RecursivelyMergedInputCapabilities()const
    CCoeControl::RefetchPixelMappingL()
    CCoeControl::RemoveFromParent()
    CCoeControl::ReportEventL(MCoeControlObserver::TCoeEvent)
    CCoeControl::RequestRelayout(const CCoeControl *)
    CCoeControl::ResetGc()const
    CCoeControl::ScreenFont(const TCoeFont &)const
    CCoeControl::SetAdjacent(TInt)
    CCoeControl::SetAllowStrayPointers()
    CCoeControl::SetBackground(const MCoeControlBackground *)
    CCoeControl::SetBlank()
    CCoeControl::SetCanDrawOutsideRect()
    CCoeControl::SetComponentsToInheritVisibility(TBool)
    CCoeControl::SetContainerWindowL(RBackedUpWindow &)
    CCoeControl::SetContainerWindowL(RWindow &)
    CCoeControl::SetContainerWindowL(const CCoeControl &)
    CCoeControl::SetControlContext(MCoeControlContext *)
    CCoeControl::SetCornerAndSize(TGulAlignment,const TSize &)
    CCoeControl::SetCustomGc(CWindowGc *)
    CCoeControl::SetDimmed(TBool)
    CCoeControl::SetExtent(const TPoint &,const TSize &)
    CCoeControl::SetExtentToWholeScreen()
    CCoeControl::SetFocus(TBool,TDrawNow)
    CCoeControl::SetFocusing(TBool)
    CCoeControl::SetFontProviderL(const CCoeFontProvider &)
    CCoeControl::SetGc(CWindowGc *)const
    CCoeControl::SetGloballyCapturing(TBool)
    CCoeControl::SetHitTest(const MCoeControlHitTest *)
    CCoeControl::SetLayoutManagerL(MCoeLayoutManager *)
    CCoeControl::SetMaximumWidth(TInt)
    CCoeControl::SetMopParent(MObjectProvider *)
    CCoeControl::SetNeighbor(CCoeControl *)
    CCoeControl::SetNonFocusing()
    CCoeControl::SetObserver(MCoeControlObserver *)
    CCoeControl::SetParent(CCoeControl *)
    CCoeControl::SetPointerCapture(TBool)
    CCoeControl::SetPosition(const TPoint &)
    CCoeControl::SetRect(const TRect &)
    CCoeControl::SetSize(const TSize &)
    CCoeControl::SetSizeWithoutNotification(const TSize &)
    CCoeControl::SetTextBaselineSpacing(TInt)
    CCoeControl::SetUniqueHandle(TInt)
    CCoeControl::SetZoomFactorL(TInt,TZoomType)
    CCoeControl::Size()const
    CCoeControl::SizeChanged()
    CCoeControl::SystemGc()const
    CCoeControl::TextBaselineOffset(const TSize &)const
    CCoeControl::TextDrawer(TInt)const
    CCoeControl::UniqueHandle()const
    CCoeControl::Window()const
    CCoeControl::WriteInternalStateL(RWriteStream &)const
    CCoeControl::WriteInternalStateNowL(RWriteStream &)const
    CCoeControl::ZoomWithType()const
    CCoeControl::operator=(const CCoeControl &)
    CCoeControl::~CCoeControl()

    Detailed Description

    The base class for Bio controls.

    Member Attribute Documentation

    iBioControlObserver

    MMsgBioControlObserver &iBioControlObserver[protected]

    Reference to the MMsgBioControlObserver.

    iId

    TMsvId iId[protected]

    Id of the message in the server.

    Constructor & Destructor Documentation

    CMsgBioControl ( MMsgBioControlObserver &, CMsvSession *, TMsvId, TMsgBioMode, const RFile * )

    IMPORT_CCMsgBioControl(MMsgBioControlObserver &aObserver,
    CMsvSession *aSession,
    TMsvIdaId,
    TMsgBioModeaEditorOrViewerMode,
    const RFile *aFile
    )

    Constructor. Call this from your Bio Control constructor.

    ParameterDescription
    aObserverReference to the Bio control observer.
    aSessionMessage Server session. Ownership not transferred.
    aIdId of the message in the server.
    aEditorOrViewerModeSets Bio Control into editor or viewer mode.
    aFileData file handle. Bio controls can also be file based. Not owned.

    ~CMsgBioControl ( )

    IMPORT_C~CMsgBioControl()

    Destructor

    Member Function Documentation

    AddMenuItemL ( CEikMenuPane &, TInt, TInt, TInt )

    IMPORT_C voidAddMenuItemL(CEikMenuPane &aMenuPane,
    TIntaStringRes,
    TIntaCommandOffset,
    TIntaPosition = 0
    )[protected]

    Adds a menu item to the menu pane which is given as a reference.

    ParameterDescription
    aMenuPaneReference to the menu pane.
    aStringResThe string resource id.
    aCommandOffsetThe offset of the command from the first free command.
    aPositionThe inserting position. The default is at the top.

    ConfirmationQueryL ( const TDesC & )

    IMPORT_C TBoolConfirmationQueryL(const TDesC &aText)[static]

    Pops a confirmation query. The result is given by the return value. The standard resource must have been loaded using LoadStandardBioResourceL().

    ParameterDescription
    aTextThe text that is to be used in the query.

    Returns: A user confirmation results in ETrue, and vice versa.

    ConfirmationQueryL ( TInt )

    IMPORT_C TBoolConfirmationQueryL(TIntaStringResource)[static]

    Pops a confirmation query. The result is given by the return value. The standard resource must have been loaded using LoadStandardBioResourceL(). Your resource must also be loaded, for eg. with LoadResourceL(). CCoeEnv must exist.

    ParameterDescription
    aStringResourceThe string resource id.

    Returns: A user confirmation results in ETrue, and vice versa.

    FileHandle ( )

    IMPORT_C const RFile &FileHandle()const [protected]
    Deprecated* Handle is valid only at contsruction phase!! To be removed. Returns input file handle.
    Exceptions
    Panics

    if the control is not file based.

    Returns: handle of file.

    FileName ( )

    IMPORT_C const TFileName &FileName()const [protected]

    Deprecated*

    Returns name of input file.
    Exceptions
    Panics

    if the control is not file based.

    Returns: Name of file.

    IsCursorLocation ( TMsgCursorLocation )

    IMPORT_C TBoolIsCursorLocation(TMsgCursorLocationaLocation)const

    Tells whether the cursor is in the topmost or bottom position. It is used by the scrolling framework.

    ParameterDescription
    aLocationSpecifies either top or bottom.

    Returns: ETrue if the cursor is in the part specified by aLocation.

    IsEditor ( )

    IMPORT_C TBoolIsEditor()const [protected]

    Returns true if the control has been launched as editor, and false if it was launched as viewer.

    Returns: ETrue or EFalse

    IsFileBased ( )

    IMPORT_C TBoolIsFileBased()const [protected]

    Is the Bio Control file based or not.

    Returns: ETrue if is file based.

    LoadResourceL ( const TDesC & )

    IMPORT_C voidLoadResourceL(const TDesC &aFile)[protected]

    Loads a resource file from /system/data/ into eikon env. This function should be used for loading the Bio Control resources. The resources are unloaded in the destructor of this class. The offsets are kept in iResourceOffsets.

    ParameterDescription
    aFileFile name mask, for eg. "vcalbc.r??".

    LoadResourceL ( const TDesC &, const TDesC & )

    IMPORT_C voidLoadResourceL(const TDesC &aFile,
    const TDesC &aSearchPath
    )[protected]

    Loads a resource file into eikon env. The resources are unloaded in the destructor of this class. (the offsets are kept in iResourceOffsets).

    ParameterDescription
    aFileFile name mask, for eg. "vcalbc.r??".
    aSearchPathSearch path, for eg. "\\System\\libs\\".

    LoadStandardBioResourceL ( )

    IMPORT_C voidLoadStandardBioResourceL()[protected]

    This loads the msgeditorutils.rsc resource, which is needed by the dialogs and notes of this class.

    MsvSession ( )

    IMPORT_C CMsvSession &MsvSession()const [protected]
    Accessor for MsvSession. The session exists only if the Bio Control has been created as message server based.
    Exceptions
    Panics

    if there is no session.

    Returns: CMsvSession&

    NotifyEditorViewL ( TMsgBioControlEventRequest, TInt )

    IMPORT_C TBoolNotifyEditorViewL(TMsgBioControlEventRequestaRequest,
    TIntaDelta = 0
    )[protected]

    Notify editor view. This is used by the Bio Control for notifying the Editor Base framework of an event, and usually for requesting something to be done.

    NotifyViewEvent ( TMsgViewEvent, TInt )

    IMPORT_C voidNotifyViewEvent(TMsgViewEventaEvent,
    TIntaParam
    )
    Prepares control for viewing.
    Since
    3.2
    ParameterDescription
    aEventThe event type
    aParamEvent related parameters

    OptionMenuPermissionsL ( )

    IMPORT_C TUint32OptionMenuPermissionsL()const

    The application can get the option menu recommendations using this function. The function comes from MMsgBioControl. This is the default implementation which returns the flags EMsgBioCallBack | EMsgBioDelete | EMsgBioMessInfo | EMsgBioMove | EMsgBioCreateCC | EMsgBioSend | EMsgBioAddRecipient | EMsgBioSave | EMsgBioSendingOpt | EMsgBioHelp | EMsgBioExit. Bio Controls should override this if it is not ok.

    Returns: The option menu permission flags. If the flag is off it means that the option menu command is not recommended with this Bio Control.

    ScrollL ( TInt, TMsgScrollDirection )

    IMPORT_C TIntScrollL(TIntaPixelsToScroll,
    TMsgScrollDirectionaDirection
    )
    Performs the internal scrolling of control if needed. Default implementation does not perform any scrolling and returns that zero pixels were scrolled.
    Since
    3.2
    ParameterDescription
    aPixelsToScrollAmount of pixels to scroll.
    aDirectionScrolling direction.

    Returns: Amount of pixels the where scrolled. Zero value means the component cannot be scrolled to that direction anymore and view should be moved.

    SetExtension ( MMsgBioControlExtension * )

    IMPORT_C voidSetExtension(MMsgBioControlExtension *aExt)[protected]

    Call from base class if extension interface is supported.

    VirtualHeight ( )

    IMPORT_C TIntVirtualHeight()

    Gives the height of the text in pixels. It is used by the scrolling framework.

    Returns: Height of the text in pixels.

    VirtualVisibleTop ( )

    IMPORT_C TIntVirtualVisibleTop()

    Gives the cursor position in pixels. It is used by the scrolling framework.

    Returns: Cursor position in pixels.