+ entry.accelerator = (gchar*) NULL;
+ char hotbuf[50];
+ wxString hotkey( mitem->GetHotKey() );
+ if (!hotkey.IsEmpty())
+ {
+ switch (hotkey[0])
+ {
+ case _T('a'): /* Alt */
+ case _T('A'):
+ case _T('m'): /* Meta */
+ case _T('M'):
+ {
+ strcpy( hotbuf, "<alt>" );
+ wxString last = hotkey.Right(1);
+ strcat( hotbuf, last.mb_str() );
+ entry.accelerator = hotbuf;
+ break;
+ }
+ case _T('c'): /* Ctrl */
+ case _T('C'):
+ case _T('s'): /* Strg, yeah man, I'm German */
+ case _T('S'):
+ {
+ strcpy( hotbuf, "<control>" );
+ wxString last = hotkey.Right(1);
+ strcat( hotbuf, last.mb_str() );
+ entry.accelerator = hotbuf;
+ break;
+ }
+ case _T('F'): /* function keys */
+ {
+ strcpy( hotbuf, hotkey.mb_str() );
+ entry.accelerator = hotbuf;
+ break;
+ }
+ default:
+ {
+ }
+ }
+ }
+