#include <mw/eiklbx.h>
class CEikSnakingListBox : public CEikListBox |
Public Member Functions | |
---|---|
CEikSnakingListBox() | |
~CEikSnakingListBox() | |
IMPORT_C TInt | ColumnWidth() |
virtual IMPORT_C void | HandlePointerEventL(const TPointerEvent &) |
virtual IMPORT_C CListBoxView * | MakeViewClassInstanceL() |
IMPORT_C void | SetColumnWidth(TInt) |
virtual IMPORT_C void | SetTopItemIndex(TInt) |
Protected Member Functions | |
---|---|
virtual IMPORT_C TInt | AdjustRectHeightToWholeNumberOfItems(TRect &) |
virtual IMPORT_C void | AdjustTopItemIndex() |
virtual IMPORT_C void | GetColorUseListL(CArrayFix< TCoeColorUse > &) |
virtual IMPORT_C void | HandleDragEventL(TPoint) |
virtual IMPORT_C void | HandleLeftArrowKeyL(CListBoxView::TSelectionMode) |
virtual IMPORT_C void | HandleResourceChange(TInt) |
virtual IMPORT_C void | HandleRightArrowKeyL(CListBoxView::TSelectionMode) |
virtual IMPORT_C void | HandleViewRectSizeChangeL() |
virtual IMPORT_C TInt | HorizScrollGranularityInPixels() |
virtual IMPORT_C TInt | HorizontalNudgeValue() |
IMPORT_C void | MoveToNextOrPreviousItemL(TPoint) |
virtual IMPORT_C void | RestoreClientRectFromViewRect(TRect &) |
virtual IMPORT_C void | SizeChanged() |
Inherited Enumerations | |
---|---|
CCoeControl:TZoomType | |
CEikListBox:@160 | |
CEikListBox:TFlags | |
CEikListBox:TReasonForFocusLost | |
CEikListBox:TScrollBarOwnerShip |
This is a list box that scrolls horizontally, displaying its items in as many vertical columns as needed. Columns are arranged across the control from left to right; within columns, items are arranged from top to bottom. The flow of items or text ?snakes? across the face of the control.
This is a flexible control class that makes good use of short, wide display areas; for instance, subclasses of CEikSnakingListBox could be used for file lists or for a control panel. A standard user subclass, CEikSnakingTextListBox, also exists.
Reimplemented from CEikListBox::AdjustRectHeightToWholeNumberOfItems(TRect &)const
Rounds down the height of the rectangle (if necessary) so that only a whole number of items can be displayed inside the list box.
Parameter | Description |
---|---|
aRect | The rectangle to be modified. |
Returns: The number of pixels reduced.
IMPORT_C void | AdjustTopItemIndex | ( | ) | const [protected, virtual] |
Reimplemented from CEikListBox::AdjustTopItemIndex()const
Called by various functions of this class to ensure that the top item index is always a sane value. The implementation in CEikListBox tries to ensure the minimum amount of white space at the bottom of the list box. Note that this function does not affect the current item index.
IMPORT_C TInt | ColumnWidth | ( | ) | const |
Gets the width of this list box?s columns.
Returns: Width of each column.
IMPORT_C void | GetColorUseListL | ( | CArrayFix< TCoeColorUse > & | aColorUseList | ) | const [protected, virtual] |
Reimplemented from CEikListBox::GetColorUseListL(CArrayFix< TCoeColorUse > &)const
From CCoeControl
Gets the list of logical colours employed in the drawing of the control, paired with an explanation of how they are used. Appends the list to aColorUseList.
Parameter | Description |
---|---|
aColorUseList | List of logical colours. |
IMPORT_C void | HandleDragEventL | ( | TPoint | aPointerPos | ) | [protected, virtual] |
Reimplemented from CEikListBox::HandleDragEventL(TPoint)
Handles drag events.
This function is called by HandlePointerEventL() to handle pointer drag events appropriately.
Parameter | Description |
---|---|
aPointerPos | The position of the TPointerEvent for which this handler is invoked. |
IMPORT_C void | HandleLeftArrowKeyL | ( | CListBoxView::TSelectionMode | aSelectionMode | ) | [protected, virtual] |
Reimplemented from CEikListBox::HandleLeftArrowKeyL(CListBoxView::TSelectionMode)
Handles a left arrow key event.
Moves the cursor into the correct column and clears any matcher buffer that may have been built up.
Parameter | Description |
---|---|
aSelectionMode | Not used. |
IMPORT_C void | HandlePointerEventL | ( | const TPointerEvent & | aPointerEvent | ) | [virtual] |
Reimplemented from CEikListBox::HandlePointerEventL(const TPointerEvent &)
From CCoeControl.
Handles pointer events.
Parameter | Description |
---|---|
aPointerEvent | The pointer event. |
IMPORT_C void | HandleResourceChange | ( | TInt | aType | ) | [protected, virtual] |
Reimplemented from CEikListBox::HandleResourceChange(TInt)
From CCoeControl.
Handles a change to the list box?s resources of type aType which are shared across the environment, colours or fonts for example.
Parameter | Description |
---|---|
aType | The type of resources that have changed. |
IMPORT_C void | HandleRightArrowKeyL | ( | CListBoxView::TSelectionMode | aSelectionMode | ) | [protected, virtual] |
Reimplemented from CEikListBox::HandleRightArrowKeyL(CListBoxView::TSelectionMode)
Handles a right arrow key event.
Moves the cursor into the correct column and clears any matcher buffer that may have been built up.
Parameter | Description |
---|---|
aSelectionMode | Not used. |
IMPORT_C void | HandleViewRectSizeChangeL | ( | ) | [protected, virtual] |
Reimplemented from CEikListBox::HandleViewRectSizeChangeL()
Handles a change in size of the viewing rectangle.
This function is called by framework functions to update the content, view, and scroll bars of this list box after the viewing rectangle has changed size. This implementation ensures that the current item is visible after a resize.
IMPORT_C TInt | HorizScrollGranularityInPixels | ( | ) | const [protected, virtual] |
Reimplemented from CEikListBox::HorizScrollGranularityInPixels()const
Gets the granularity for horizontal scrolls.
The granularity is the minimum size of a horizontal move of the client area.
Returns: Grain size for horizontal scrolling in pixels.
IMPORT_C TInt | HorizontalNudgeValue | ( | ) | const [protected, virtual] |
Reimplemented from CEikListBox::HorizontalNudgeValue()const
Gets the number of grains to move horizontally when a nudge button is tapped.
For simple list boxes, this value is a fraction of the width of the client area.
Returns: Number of grains to move left or right on each nudge.
IMPORT_C CListBoxView * | MakeViewClassInstanceL | ( | ) | [virtual] |
Reimplemented from CEikListBox::MakeViewClassInstanceL()
Creates an instance of the view class.
This function is called during construction to create (but not second-phase construct) an instance of the correct view class for this list box control. In the case of the snaking list box, a CSnakingListBoxView is returned.
This function overrides CEikListBox::MakeViewClassInstanceL().
Returns: The view which will be used by the list box being created
IMPORT_C void | MoveToNextOrPreviousItemL | ( | TPoint | aPoint | ) | [protected] |
Move to next or previous item according to the given parameter.
Parameter | Description |
---|---|
aPoint | Position which defines the moving direction. |
IMPORT_C void | RestoreClientRectFromViewRect | ( | TRect & | aClientRect | ) | const [protected, virtual] |
Reimplemented from CEikListBox::RestoreClientRectFromViewRect(TRect &)const
Calculates the client area.
This method is called by various functions of this class to recalculate the extent of the client area from iViewRect. This implementation takes into account any rounding of the viewing rectangle made to fit a whole number of items.
Parameter | Description |
---|---|
aClientRect | On return contains a size for the client area in pixels. |
IMPORT_C void | SetColumnWidth | ( | TInt | aColumnWidth | ) |
Sets the width of all columns in the list box.
Parameter | Description |
---|---|
aColumnWidth | New column width. |
IMPORT_C void | SetTopItemIndex | ( | TInt | aItemIndex | ) | const [virtual] |
Reimplemented from CEikListBox::SetTopItemIndex(TInt)const
Sets the top item?s index.
Parameter | Description |
---|---|
aItemIndex | Index of the item to set as the top item. |
IMPORT_C void | SizeChanged | ( | ) | [protected, virtual] |
Reimplemented from CEikListBox::SizeChanged()
From CCoeControl
Updates the viewing rectangle of this control appropriately. The function updates the viewing rectangle, and invokes HandleViewRectSizeChangeL().