Class evab::WindowAlgorithmBase¶
ClassList > evab > WindowAlgorithmBase
Abstract base class for window navigation algorithms. More...
#include <evabWindowAlgorithms.h>
Inherited by the following classes: evab::FlipWindowAlgorithm, evab::ScrollWindowAlgorithm
Public Functions¶
| Type | Name |
|---|---|
| unsigned char | Count () Gets the total number of items. |
| virtual void | Select (unsigned char aIndex) = 0 Pure virtual method to select an item. |
| signed short | Selected () Gets the currently selected item index. |
| WindowAlgorithmBase (unsigned char aCount=0) Constructor for window algorithm base. |
|
| unsigned char | WindowSize () Gets the window size. |
Protected Attributes¶
| Type | Name |
|---|---|
| unsigned char | mCount Total number of items. |
| unsigned char | mSelected Currently selected index. |
| unsigned char | mWindowSize Window size. |
| unsigned char | mWindowStart Start of the current window. |
Protected Functions¶
| Type | Name |
|---|---|
| signed char | indexInWindow (unsigned char aPosition) Calculates the visual index of an item in the current window. |
| void | setCount (unsigned char aCount) Sets the total number of items. |
| void | setWindowSize (unsigned char aWindowSize) Resizes the window. |
Detailed Description¶
Provides common functionality for list box navigation strategies.
Public Functions Documentation¶
function Count¶
Gets the total number of items.
unsigned char evab::WindowAlgorithmBase::Count ()
Returns:
Total number of items
function Select¶
Pure virtual method to select an item.
virtual void evab::WindowAlgorithmBase::Select (
unsigned char aIndex
) = 0
Parameters:
aIndexIndex to select
function Selected¶
Gets the currently selected item index.
signed short evab::WindowAlgorithmBase::Selected ()
Returns:
Selected index, or -1 if empty
function WindowAlgorithmBase¶
Constructor for window algorithm base.
evab::WindowAlgorithmBase::WindowAlgorithmBase (
unsigned char aCount=0
)
Parameters:
aCountTotal number of items
function WindowSize¶
Gets the window size.
unsigned char evab::WindowAlgorithmBase::WindowSize ()
Returns:
Window size
Protected Attributes Documentation¶
variable mCount¶
Total number of items.
unsigned char evab::WindowAlgorithmBase::mCount;
variable mSelected¶
Currently selected index.
unsigned char evab::WindowAlgorithmBase::mSelected;
variable mWindowSize¶
Window size.
unsigned char evab::WindowAlgorithmBase::mWindowSize;
variable mWindowStart¶
Start of the current window.
unsigned char evab::WindowAlgorithmBase::mWindowStart;
Protected Functions Documentation¶
function indexInWindow¶
Calculates the visual index of an item in the current window.
signed char evab::WindowAlgorithmBase::indexInWindow (
unsigned char aPosition
)
Parameters:
aPositionAbsolute position of the item
Returns:
Visual index, or -1 if not visible
function setCount¶
Sets the total number of items.
void evab::WindowAlgorithmBase::setCount (
unsigned char aCount
)
Parameters:
aCountTotal number of items
function setWindowSize¶
Resizes the window.
void evab::WindowAlgorithmBase::setWindowSize (
unsigned char aWindowSize
)
Parameters:
aWindowSizeNew window size
The documentation for this class was generated from the following file src/evabWindowAlgorithms.h