CMsgFormComponent Class Reference

class CMsgFormComponent : public CEikBorderedControl

Defines a base class for message editor/viewer form component (header or body).

Public Member Functions
CMsgFormComponent(const TMargins &)
~CMsgFormComponent()
voidAddControlL(CMsgBaseControl *, TInt, TInt)
voidBaseConstructL(const CCoeControl &)
TBool ChangeFocusTo(TInt, TDrawNow)
CMsgBaseControl *Component(TInt)
CCoeControl *ComponentControl(TInt)
TInt ComponentIndexFromId(TInt)
CMsgBaseControl *ControlFromPosition(TPoint, TBool)
TInt CountComponentControls()
TInt CountMsgControls()
TInt CurrentFocus()
TRect CurrentLineRect()
TInt FirstFocusableControl(TInt, TMsgFocusDirection)
CMsgBaseControl *FocusedControl()
TMargins Margins()
CMsgBaseControl *MsgControl(TInt)
voidNotifyControlsForEvent(TMsgViewEvent, TInt)
TKeyResponse OfferKeyEventL(const TKeyEvent &, TEventCode)
CMsgBaseControl *RemoveControlL(TInt)
voidResetControls()
voidSetAndGetSizeL(TSize &, TBool)
TInt VirtualExtension()
TInt VirtualHeight()
Protected Member Functions
voidFocusChanged(TDrawNow)
voidHandleResourceChange(TInt)
voidSizeChanged()
Private Member Functions
CMsgFormComponent()
TInt DoAddControlL(CMsgBaseControl *, TInt)
Inherited Functions
CAknControl::CAknControl()
CAknControl::~CAknControl()
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::Components()
CCoeControl::Components()const
CCoeControl::ConstructFromResourceL(TResourceReader &)
CCoeControl::ControlContext()const
CCoeControl::ControlEnv()const
CCoeControl::CopyControlContextFrom(const CCoeControl *)
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::GetColor(TInt,TRgb &)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::HandleRedrawEvent(const TRect &)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::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::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::SystemGc()const
CCoeControl::TextBaselineOffset(const TSize &)const
CCoeControl::TextDrawer(TInt)const
CCoeControl::UniqueHandle()const
CCoeControl::Window()const
CCoeControl::WriteInternalStateNowL(RWriteStream &)const
CCoeControl::ZoomWithType()const
CCoeControl::operator=(const CCoeControl &)
CCoeControl::~CCoeControl()
CEikBorderedControl::Border()const
CEikBorderedControl::CEikBorderedControl()
CEikBorderedControl::CEikBorderedControl(const TGulBorder &)
CEikBorderedControl::Draw(const TRect &)const
CEikBorderedControl::GetColorUseListL(CArrayFix< TCoeColorUse > &)const
CEikBorderedControl::HandlePointerEventL(const TPointerEvent &)
CEikBorderedControl::HasBorder()const
CEikBorderedControl::SetAdjacent(TInt)
CEikBorderedControl::SetBorder(TGulBorder::TBorderType)
CEikBorderedControl::SetBorder(TInt)
CEikBorderedControl::WriteInternalStateL(RWriteStream &)const
Inherited Enumerations
CCoeControl:TZoomType
Protected Attributes
CMsgControlArray *iControls
TInt iCurrentFocus
TMargins iMargins
Inherited Attributes
CCoeControl::iCoeEnv
CCoeControl::iContext
CCoeControl::iPosition
CCoeControl::iSize
CEikBorderedControl::iBorder

Constructor & Destructor Documentation

CMsgFormComponent(const TMargins &)

CMsgFormComponent(const TMargins &aMargins)

Constructor.

Parameters

const TMargins & aMargins

CMsgFormComponent()

CMsgFormComponent()[private]

Constructor (not available).

~CMsgFormComponent()

~CMsgFormComponent()[virtual]

Destructor.

Member Functions Documentation

AddControlL(CMsgBaseControl *, TInt, TInt)

voidAddControlL(CMsgBaseControl *aControl,
TIntaControlId,
TIntaIndex = 0
)

Adds a control aControl to the control array to position aIndex and sets control id for the control.

Parameters

CMsgBaseControl * aControl
TInt aControlId
TInt aIndex = 0

BaseConstructL(const CCoeControl &)

voidBaseConstructL(const CCoeControl &aParent)

Parameters

const CCoeControl & aParent

ChangeFocusTo(TInt, TDrawNow)

TBool ChangeFocusTo(TIntaNewFocus,
TDrawNowaDrawNow = EDrawNow
)

Changes focus to a control whose index is aNewFocus. Returns EFalse if focus cannot be changed.

Parameters

TInt aNewFocus
TDrawNow aDrawNow = EDrawNow

Component(TInt)

CMsgBaseControl *Component(TIntaControlId)const

Return a pointer to a control by given control id aControlId. If the control cannot be found returns NULL.

Parameters

TInt aControlId

ComponentControl(TInt)

CCoeControl *ComponentControl(TIntaIndex)const [virtual]

Returns a control of index aIndex.

Parameters

TInt aIndex

ComponentIndexFromId(TInt)

TInt ComponentIndexFromId(TIntaControlId)const

Returns control's array index by given control id aControlId.

Parameters

TInt aControlId

ControlFromPosition(TPoint, TBool)

CMsgBaseControl *ControlFromPosition(TPointaPosition,
TBoolaEvaluateHitTest
)const

Returns control which is located at given position.

Since
3.2

Parameters

TPoint aPositionGiven position.
TBool aEvaluateHitTest

CountComponentControls()

TInt CountComponentControls()const [virtual]

Returns a number of controls.

CountMsgControls()

TInt CountMsgControls()const

Returns a number of MsgBaseControl based controls

CurrentFocus()

TInt CurrentFocus()const

Returns index of currently focused control.

CurrentLineRect()

TRect CurrentLineRect()

Returns the current control rect.

DoAddControlL(CMsgBaseControl *, TInt)

TInt DoAddControlL(CMsgBaseControl *aControl,
TIntaIndex
)[private]

Adds control aControl to the component array to position aIndex. If aIndex = the number components in the array or EMsgAppendControl, appends the control to end of the array. Panics is aIndex is incorrect.

Parameters

CMsgBaseControl * aControl
TInt aIndex

FirstFocusableControl(TInt, TMsgFocusDirection)

TInt FirstFocusableControl(TIntaStart,
TMsgFocusDirectionaDirection
)

Return index of first focusable control

Parameters

TInt aStartstart index to search.
TMsgFocusDirection aDirectiondirection to search.

FocusChanged(TDrawNow)

voidFocusChanged(TDrawNowaDrawNow)[protected, virtual]

This is called when the focus of the control is changed.

Parameters

TDrawNow aDrawNow

FocusedControl()

CMsgBaseControl *FocusedControl()const

Returns a pointer to the focused control.

HandleResourceChange(TInt)

voidHandleResourceChange(TIntaType)[protected, virtual]

From CCoeControl Handles a resource relative event

Parameters

TInt aType

Margins()

TMargins Margins()const

Returns margins.

MsgControl(TInt)

CMsgBaseControl *MsgControl(TIntaIndex)const

Returns a MsgBaseControl based control of index aIndex.

Parameters

TInt aIndex

NotifyControlsForEvent(TMsgViewEvent, TInt)

voidNotifyControlsForEvent(TMsgViewEventaEvent,
TIntaParam
)[virtual]

Parameters

TMsgViewEvent aEvent
TInt aParam

OfferKeyEventL(const TKeyEvent &, TEventCode)

TKeyResponse OfferKeyEventL(const TKeyEvent &aKeyEvent,
TEventCodeaType
)[virtual]

Handles key events.

Parameters

const TKeyEvent & aKeyEvent
TEventCode aType

RemoveControlL(TInt)

CMsgBaseControl *RemoveControlL(TIntaControlId)

Removes a control from array by given control id aControlId and returns pointer to it. If the control cannot be found retuns NULL.

Parameters

TInt aControlId

ResetControls()

voidResetControls()

Resets (= clears) controls from this component.

SetAndGetSizeL(TSize &, TBool)

voidSetAndGetSizeL(TSize &aSize,
TBoolaInit
)[pure virtual]

Calculates and sets the size for the control and returns new size as reference aSize. If aInit == ETrue, sets also size for the controls by calling their SetAndGetSizeL functions.

Parameters

TSize & aSize
TBool aInit

SizeChanged()

voidSizeChanged()[protected, virtual]

Sets new position for all the controls.

VirtualExtension()

TInt VirtualExtension()

Returns total of pixels above each control' band. This function is needed for the scroll bar for estimating message form's position relative to screen.

VirtualHeight()

TInt VirtualHeight()

Return virtual height of components.

Member Data Documentation

CMsgControlArray * iControls

CMsgControlArray *iControls[protected]

TInt iCurrentFocus

TInt iCurrentFocus[protected]

TMargins iMargins

TMargins iMargins[protected]