CMsgBioControl Class Reference

class CMsgBioControl : public CCoeControl

The base class for Bio controls.

Inherits from

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 *)
Private Member Functions
CMsgBioControl()
CMsgBioControl(const CMsgBioControl &)
TBool IsNear(TInt, TInt)
voidSetBioBodyControl(MMsgBioBodyControl *)
const CMsgBioControl &operator=(const CMsgBioControl &)
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::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()
Inherited Enumerations
CCoeControl:TZoomType
Protected Attributes
MMsgBioControlObserver &iBioControlObserver
TMsvId iId
Private Attributes
TUint8 iBCFiller
TInt iBCStatusFlags
MMsgBioBodyControl *iBioBodyControl
MMsgBioControlExtension *iExt
const RFile *iFile
TMsgBioMode iMode
CMsvSession *iMsvSession
CArrayFixFlat< TInt > *iResourceOffsets
Inherited Attributes
CCoeControl::iCoeEnv
CCoeControl::iContext
CCoeControl::iPosition
CCoeControl::iSize

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.

Parameters

MMsgBioControlObserver & aObserverReference to the Bio control observer.
CMsvSession * aSessionMessage Server session. Ownership not transferred.
TMsvId aIdId of the message in the server.
TMsgBioMode aEditorOrViewerModeSets Bio Control into editor or viewer mode.
const RFile * aFileData file handle. Bio controls can also be file based. Not owned.

CMsgBioControl()

CMsgBioControl()[private]

Default constructor hidden away

CMsgBioControl(const CMsgBioControl &)

CMsgBioControl(const CMsgBioControl &aSource)[private]

Copy constructor prohibited.

Parameters

const CMsgBioControl & aSource

~CMsgBioControl()

IMPORT_C~CMsgBioControl()

Destructor

Member Functions 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.

Parameters

CEikMenuPane & aMenuPaneReference to the menu pane.
TInt aStringResThe string resource id.
TInt aCommandOffsetThe offset of the command from the first free command.
TInt aPosition = 0The 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().

Parameters

const TDesC & aTextThe text that is to be used in the query.

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.

Parameters

TInt aStringResourceThe string resource id.

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.

FileName()

IMPORT_C const TFileName &FileName()const [protected]

Deprecated*

Returns name of input file.
Exceptions
Panics

if the control is not file based.

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.

Parameters

TMsgCursorLocation aLocationSpecifies either top or bottom.

IsEditor()

IMPORT_C TBoolIsEditor()const [protected]

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

IsFileBased()

IMPORT_C TBoolIsFileBased()const [protected]

Is the Bio Control file based or not.

IsNear(TInt, TInt)

TBool IsNear(TIntaLafPos,
TIntaPos
)const [private]

Parameters

TInt aLafPos
TInt aPos

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.

Parameters

const TDesC & 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).

Parameters

const TDesC & aFileFile name mask, for eg. "vcalbc.r??".
const TDesC & 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.

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.

Parameters

TMsgBioControlEventRequest aRequest
TInt aDelta = 0

NotifyViewEvent(TMsgViewEvent, TInt)

IMPORT_C voidNotifyViewEvent(TMsgViewEventaEvent,
TIntaParam
)
Prepares control for viewing.
Since
3.2

Parameters

TMsgViewEvent aEventThe event type
TInt 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.

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

Parameters

TInt aPixelsToScrollAmount of pixels to scroll.
TMsgScrollDirection aDirectionScrolling direction.

SetBioBodyControl(MMsgBioBodyControl *)

voidSetBioBodyControl(MMsgBioBodyControl *aBioBodyControl)[private]

Sets the bio body control reference. Used only by CMsgBioBodyControl.

Parameters

MMsgBioBodyControl * aBioBodyControlAddress of the bio body control.

SetExtension(MMsgBioControlExtension *)

IMPORT_C voidSetExtension(MMsgBioControlExtension *aExt)[protected]

Call from base class if extension interface is supported.

Parameters

MMsgBioControlExtension * aExt

VirtualHeight()

IMPORT_C TIntVirtualHeight()

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

VirtualVisibleTop()

IMPORT_C TIntVirtualVisibleTop()

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

operator=(const CMsgBioControl &)

const CMsgBioControl &operator=(const CMsgBioControl &aSource)[private]

Assignment operator prohibited.

Parameters

const CMsgBioControl & aSource

Member Data Documentation

TUint8 iBCFiller

TUint8 iBCFiller[private]

TInt iBCStatusFlags

TInt iBCStatusFlags[private]

MMsgBioBodyControl * iBioBodyControl

MMsgBioBodyControl *iBioBodyControl[private]

MMsgBioControlObserver & iBioControlObserver

MMsgBioControlObserver &iBioControlObserver[protected]

MMsgBioControlExtension * iExt

MMsgBioControlExtension *iExt[private]

A pointer to Bio control extension interface. It is not owned here.

const RFile * iFile

const RFile *iFile[private]

* Deprecated -> To be removed* Handle is valid only during contruction phase. A pointer to the handle of the input file, not owned. Accessed using FileHandle(). See also function FileBased().

TMsvId iId

TMsvId iId[protected]

TMsgBioMode iMode

TMsgBioMode iMode[private]

CMsvSession * iMsvSession

CMsvSession *iMsvSession[private]

Pointer to Message Server session. It is NOT owned here. The reason for using pointer type is that the session is optional. It can be NULL without implying any error. This session is accessed using the function MsvSession().

CArrayFixFlat< TInt > * iResourceOffsets

CArrayFixFlat< TInt > *iResourceOffsets[private]