CAknMessageQueryControl Class Reference

class CAknMessageQueryControl : public CAknControl

Interface to control to implement message queries, to be contained within CAknMessageQueryDialog.

0.9

Inherits from

Public Member Functions
CAknMessageQueryControl()
~CAknMessageQueryControl()
voidActivateL()
CCoeControl *ComponentControl(TInt)
IMPORT_C voidConstructFromResourceL(TResourceReader &)
TInt CountComponentControls()
TInt CurrentLink()
voidDehighlightLink()
voidHandlePointerEventL(const TPointerEvent &)
TInt Lines()
IMPORT_C TBoolLinkHighLighted()
TBool LinkTappedL(TInt)
TSize MinimumSize()
TKeyResponse OfferKeyEventL(const TKeyEvent &, TEventCode)
TBool ScrollBarGrabbing()
voidSetListQLayout(TBool)
IMPORT_C voidSetMessageTextL(TDesC *)
voidSetMessageTextWithFormattingL(TDesC *, RArray< TDesC * > *, RArray< TInt > *, RArray< TMsgQueryTag > *)
voidSizeChanged()
Protected Member Functions
IMPORT_C voidDraw(const TRect &)
TRect LayoutRect()
Private Member Functions
TBool CanScrollPage(TBool)
voidCreateEditorL()
voidDoSizeChangedL()
TBool IsLinkVisible(TInt)
voidLayoutEditorL()
TBool SetCurPosL(TInt)
voidSetHighlightOnL(TBool)
voidTruncateTextForListQLayout(TDes &)
voidUpdatePageInfo()
voidUpdateScrollIndicatorL()
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::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::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::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::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::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::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::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
Private Attributes
TCharFormat iCharFormat
TCharFormatMask iCharFormatMask
TInt iCurPos
CEikRichTextEditor *iEdwin
CAknMessageQueryControlExtension *iExtension
TInt iFirstVisibleLink
TDesC *iFullMessage
TBool iHighlightOn
TInt iLinesPerPage
RArray< TDesC * >iLinkTextArray
RArray< TInt >iLinkTextLocationArray
TInt iLinksCount
TBool iListQLayout
TInt iNumberOfLines
TInt iPositionsCount
CEikScrollBarFrame *iSBFrame
TInt iTopLine
TInt iVisibleLinksCount
Inherited Attributes
CCoeControl::iCoeEnv
CCoeControl::iContext
CCoeControl::iPosition
CCoeControl::iSize

Constructor & Destructor Documentation

CAknMessageQueryControl()

CAknMessageQueryControl()

C++ default constructor.

~CAknMessageQueryControl()

~CAknMessageQueryControl()

Destructor.

Member Functions Documentation

ActivateL()

voidActivateL()[virtual]

From CCoeControl. Sets control as ready to be drawn. This function calls CCoeControl::ActivateL().

CanScrollPage(TBool)

TBool CanScrollPage(TBoolaMoveDown)[private]
Returns if it is possible to scroll one page in the specified direction.
  • aMoveDown The scroll direction is down, if ETrue.

Parameters

TBool aMoveDown

ComponentControl(TInt)

CCoeControl *ComponentControl(TIntanIndex)const [virtual]

From CCoeControl. Gets the specified component of a compound control. It returns one of the control's component controls, identified by anIndex. The component control with an index of anIndex.

Parameters

TInt anIndexThe index of the control to get.

ConstructFromResourceL(TResourceReader &)

IMPORT_C voidConstructFromResourceL(TResourceReader &aReader)[virtual]

Constructs controls from a resource file.

Parameters

TResourceReader & aReaderThe resource reader with which to access AVKON_MESSAGE_QUERY resource.

CountComponentControls()

TInt CountComponentControls()const [virtual]

From CCoeControl. Gets the number of controls contained in a compound control. The number of component controls contained by this control.

CreateEditorL()

voidCreateEditorL()[private]

CurrentLink()

TInt CurrentLink()const

Fetches the current link chosen by the UI. 3.0

The index of the link or -1 if no link is chosen.

DehighlightLink()

voidDehighlightLink()

Dehighlights the current link (if any is selected) by setting the current position to 0.

DoSizeChangedL()

voidDoSizeChangedL()[private]

Draw(const TRect &)

IMPORT_C voidDraw(const TRect &aRect)const [protected, virtual]

From CCoeControl. Draw a control. 2.0

Parameters

const TRect & aRectThe region of the control to be redrawn. Not used.

HandlePointerEventL(const TPointerEvent &)

voidHandlePointerEventL(const TPointerEvent &aPointerEvent)[virtual]

From CCoeControl. Handles pointer events 3.0

Parameters

const TPointerEvent & aPointerEvent

IsLinkVisible(TInt)

TBool IsLinkVisible(TIntaIndex)const [private]

Parameters

TInt aIndex

LayoutEditorL()

voidLayoutEditorL()[private]

LayoutRect()

TRect LayoutRect()const [protected]

Get a layout rectangle (shift up and left by margins). 2.6

The layout rectangle.

Lines()

TInt Lines()const [inline]

Gets the number of lines. Number of lines.

LinkHighLighted()

IMPORT_C TBoolLinkHighLighted()const

Determines whether the link is highlighted. 2.8

ETrue if the link is highlighted.

LinkTappedL(TInt)

TBool LinkTappedL(TIntaPos)

Determines if a link is tapped. ETrue if a link is tapped.

3.2

Parameters

TInt aPosPosition of the character tapped.

MinimumSize()

TSize MinimumSize()[virtual]

From CCoeControl. Sets the control's minimum required size. The minimum size required by the control.

OfferKeyEventL(const TKeyEvent &, TEventCode)

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

Handles key events. Indicates whether or not the key event was used by this control.

Parameters

const TKeyEvent & aKeyEventThe key event.
TEventCode

ScrollBarGrabbing()

TBool ScrollBarGrabbing()

Check if scroll bar has received a pointer down event ETrue if scroll bar has received a pointer down event

SetCurPosL(TInt)

TBool SetCurPosL(TIntaCurPos)[private]

Changes the current position of the virtual cursor. Dehighlights the old link and highlights the new one, if any is selected. Checks for the valid range. EFalse if out of range, the position was not changed. ETrue if the position was changed successfully.

Parameters

TInt aCurPos

SetHighlightOnL(TBool)

voidSetHighlightOnL(TBoolaOn)[private]

Highlights or dehighlights the current link with proper font decoration.

Parameters

TBool aOn

SetListQLayout(TBool)

voidSetListQLayout(TBoolaListQLayout)

When set, controls knows that it is in listquery dialog where max. lines is 3 and background is not drawn

Parameters

TBool aListQLayout

SetMessageTextL(TDesC *)

IMPORT_C voidSetMessageTextL(TDesC *aMessage)

Sets the message text.

Parameters

TDesC * aMessageMessage text.

SetMessageTextWithFormattingL(TDesC *, RArray< TDesC * > *, RArray< TInt > *, RArray< TMsgQueryTag > *)

voidSetMessageTextWithFormattingL(TDesC *aMessage,
RArray< TDesC * > *aFormatTextArray,
RArray< TInt > *aFormatTextLocationArray,
RArray< TMsgQueryTag > *aFormatTypeArray
)

Formats message text with links and bold text. To be called from CAknMessageQueryDialog.

3.2

Parameters

TDesC * aMessage
RArray< TDesC * > * aFormatTextArrayPointer to text to be formatted
RArray< TInt > * aFormatTextLocationArrayStart index of the text
RArray< TMsgQueryTag > * aFormatTypeArrayFormat type

SizeChanged()

voidSizeChanged()[virtual]

From CCoeControl. Responds to size changes to sets the size and position of the contents of this control.

TruncateTextForListQLayout(TDes &)

voidTruncateTextForListQLayout(TDes &aMessage)[private]

Truncates the text that doesn't fit to the maximum lines number allowed for the list query layout (=3). The truncated text is expanded with the ellipsis character.

If the message query doesn't use the list query layout (iListQLayout == EFalse), this function returns immediately.

Parameters

TDes & aMessage

UpdatePageInfo()

voidUpdatePageInfo()[private]
Updates information about the current page:
  • visible links

  • cursor positions. The visible links are fetched from the links array. Number of cursor positions is calculated on the basis of visible links. Sets variables: iVisibleLinksCount, iFirstVisibleLink, iPositionsCount

UpdateScrollIndicatorL()

voidUpdateScrollIndicatorL()[private]

Member Data Documentation

TCharFormat iCharFormat

TCharFormat iCharFormat[private]

TCharFormatMask iCharFormatMask

TCharFormatMask iCharFormatMask[private]

TInt iCurPos

TInt iCurPos[private]

CEikRichTextEditor * iEdwin

CEikRichTextEditor *iEdwin[private]

CAknMessageQueryControlExtension * iExtension

CAknMessageQueryControlExtension *iExtension[private]

TInt iFirstVisibleLink

TInt iFirstVisibleLink[private]

TDesC * iFullMessage

TDesC *iFullMessage[private]

TBool iHighlightOn

TBool iHighlightOn[private]

TInt iLinesPerPage

TInt iLinesPerPage[private]

RArray< TDesC * > iLinkTextArray

RArray< TDesC * >iLinkTextArray[private]

RArray< TInt > iLinkTextLocationArray

RArray< TInt >iLinkTextLocationArray[private]

TInt iLinksCount

TInt iLinksCount[private]

TBool iListQLayout

TBool iListQLayout[private]

TInt iNumberOfLines

TInt iNumberOfLines[private]

TInt iPositionsCount

TInt iPositionsCount[private]

Cursor positions are places on the current page, where a virtual cursor can stop. The positions are considered visible links plus top and bottom of the page. Position indexes are zero-based. If there are no visible links, there is only one cursor position with index 0.

CEikScrollBarFrame * iSBFrame

CEikScrollBarFrame *iSBFrame[private]

TInt iTopLine

TInt iTopLine[private]

TInt iVisibleLinksCount

TInt iVisibleLinksCount[private]