From 428a283f83e3c9c6e683062079cacbebf43ce3ab Mon Sep 17 00:00:00 2001 From: Matthias Melcher Date: Fri, 9 Jun 2006 07:48:08 +0000 Subject: Added an event variable "Fl::event_original_key()" which returns the current key code (see Fl::event_key()) before it gets mangled through the NumLock keypad conversion. This way, an application can differentiate between an arrow key and a numeric keypad w/NumLock off. On Win32, releasing a numeric keypad key w/NumLock off wiould return the wrong keycode (keypad instead of arrow key). Documentation changed accordingly. X11 code is yet to be tested. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@5188 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- FL/Fl.H | 3 +++ 1 file changed, 3 insertions(+) (limited to 'FL') diff --git a/FL/Fl.H b/FL/Fl.H index d3cabd59d..72086ccd2 100644 --- a/FL/Fl.H +++ b/FL/Fl.H @@ -82,6 +82,8 @@ public: // should be private! static const char* scheme_; static Fl_Image* scheme_bg_; + static int e_original_keysym; // late addition + public: // API version number @@ -159,6 +161,7 @@ public: static int event_state() {return e_state;} static int event_state(int i) {return e_state&i;} static int event_key() {return e_keysym;} + static int event_original_key(){return e_original_keysym;} static int event_key(int); static int get_key(int); static const char* event_text() {return e_text;} -- cgit v1.2.3