IAcceleratorTable::Cursor

The nested class IAcceleratorTable::Cursor iterates the accelerator keys contained in an accelerator table. You use this class to return each of the IAcceleratorKey objects contained in an IAcceleratorTable.


IAcceleratorTable::Cursor - Member Functions and Data by Group

Constructors & Destructor

You can construct and destruct objects of the IAcceleratorTable::Cursor class. You cannot copy or assign IAcceleratorTable::Cursor objects because both the copy constructor and the assignment operator are private functions.


[view class]
~Cursor
public:
virtual ~Cursor()

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
Cursor
public:
Cursor(IAcceleratorTable& accelTbl)

Constructs objects of the IAcceleratorTable::Cursor class. You can use the resulting object to enumerate or manipulate the accelerator keys contained in the specified accelerator table object.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Position

You use a cursor to point to an accelerator key in an accelerator table. To iterate the keys in a table, you can query the accelerator key pointed to by a cursor, and change the entry in the table that a cursor is pointing to.


[view class]
element
public:
IAcceleratorKey element() const

Returns a copy of the accelerator key object pointed at by the cursor. To use this function, the cursor must be in a valid state.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
setToFirst
public:
virtual bool setToFirst()

Points the cursor to the first accelerator key in the accelerator table. If the table contains no accelerator keys, this function invalidates the cursor and returns false. Otherwise this function puts the cursor in a valid state and returns true.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
setToNext
public:
virtual bool setToNext()

Points the cursor to the next accelerator key in the accelerator table. If the cursor was already pointing to the last accelerator key, this function invalidates the cursor and returns false. Otherwise this function returns true.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Validation

A cursor must be in a valid state to be used in manipulating the accelerator keys in an accelerator table. While you can use the positioning members of this class to validate a cursor, you can also query whether a cursor is valid as well as invalidate it.


[view class]
invalidate
public:
virtual void invalidate()

Invalidates the cursor. You must put the cursor back into a valid state using setToFirst before you can use it to access an accelerator key.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
isValid
public:
virtual bool isValid() const

Indicates if the cursor is in a valid state. This function returns true if the cursor is valid. Otherwise it returns false.
Note: This function may return true if the cursor is in an undefined state.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


IAcceleratorTable::Cursor - Inherited Member Functions and Data

Inherited Public Functions

Inherited Public Data

Inherited Protected Functions

Inherited Protected Data