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.
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.
![]() |
public:
virtual ~Cursor()
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
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.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
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.
![]() |
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.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
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.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
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.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
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.
![]() |
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.
Windows | OS/2 | AIX |
Yes | Yes | Yes |
![]() |
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:
Windows | OS/2 | AIX |
Yes | Yes | Yes |