I thought I'd put this up for discussion before I dive in and start to hack the code apart.
Mr Tiffany notes that accelerator groups, once set, can't be modified. The other alternative are accelerator maps. However, these require you to provide some kind of unique "path" reference for each accelerator you add.
Notes from the docs :
The accelerator path must consist of "<WINDOWTYPE>/Category1/Category2/.../Action", where <WINDOWTYPE> should be a unique application-specific identifier, that corresponds to the kind of window the accelerator is being used in, e.g. "Gimp-Image", "Abiword-Document" or "Gnumeric-Settings". The Category1/.../Action portion is most appropriately chosen by the action the accelerator triggers, i.e. for accelerators on menu items, choose the item's menu path, e.g. "File/Save As", "Image/View/Zoom" or "Edit/Select All". So a full valid accelerator path may look like: "<Gimp-Toolbox>/File/Dialogs/Tool Options...".
Now, I dunno how closely these guidelines are meant to be followed, or if it is just a guideline, and we can please ourselves, but from what I understand, the GtkAccelMap is some kind of system-wide singleton...
So... any ideas?
Remember, this is MaxGUI, which is generic, so we are coding below the exposed APIs...
:o)
Mr Tiffany notes that accelerator groups, once set, can't be modified. The other alternative are accelerator maps. However, these require you to provide some kind of unique "path" reference for each accelerator you add.
Notes from the docs :
The accelerator path must consist of "<WINDOWTYPE>/Category1/Category2/.../Action", where <WINDOWTYPE> should be a unique application-specific identifier, that corresponds to the kind of window the accelerator is being used in, e.g. "Gimp-Image", "Abiword-Document" or "Gnumeric-Settings". The Category1/.../Action portion is most appropriately chosen by the action the accelerator triggers, i.e. for accelerators on menu items, choose the item's menu path, e.g. "File/Save As", "Image/View/Zoom" or "Edit/Select All". So a full valid accelerator path may look like: "<Gimp-Toolbox>/File/Dialogs/Tool Options...".
Now, I dunno how closely these guidelines are meant to be followed, or if it is just a guideline, and we can please ourselves, but from what I understand, the GtkAccelMap is some kind of system-wide singleton...
So... any ideas?
Remember, this is MaxGUI, which is generic, so we are coding below the exposed APIs...
:o)