Author: manolo
Date: 2011-06-26 00:42:07 -0700 (Sun, 26 Jun 2011)
New Revision: 8842
Log:
Mac OS: use cmd-A and cmd-C to select all and copy (instead of ctrl-A and
ctrl-C).
Modified:
branches/branch-1.3/src/Fl_Help_View.cxx
Modified: branches/branch-1.3/src/Fl_Help_View.cxx
===================================================================
--- branches/branch-1.3/src/Fl_Help_View.cxx 2011-06-25 17:42:34 UTC (rev
8841)
+++ branches/branch-1.3/src/Fl_Help_View.cxx 2011-06-26 07:42:07 UTC (rev
8842)
@@ -2940,8 +2940,6 @@
free(txt);
}
-#define ctrl(x) ((x)&0x1f)
-
/** Handles events in the widget. */
int // O - 1 if we handled it, 0 otherwise
Fl_Help_View::handle(int event) // I - Event to handle
@@ -3014,11 +3012,12 @@
}
return 1;
case FL_SHORTCUT: {
- char ascii = Fl::event_text()[0];
- switch (ascii) {
- case ctrl('A'): select_all(); redraw(); return 1;
- case ctrl('C'):
- case ctrl('X'): end_selection(1); return 1;
+ if (Fl::event_state() == FL_COMMAND) {
+ switch ( Fl::event_key() ) {
+ case 'a': select_all(); redraw(); return 1;
+ case 'c':
+ case 'x': end_selection(1); return 1;
+ }
}
break; }
}
_______________________________________________
fltk-commit mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-commit