summaryrefslogtreecommitdiffstats
path: root/views/event_gtk.cc
diff options
context:
space:
mode:
Diffstat (limited to 'views/event_gtk.cc')
-rw-r--r--views/event_gtk.cc4
1 files changed, 1 insertions, 3 deletions
diff --git a/views/event_gtk.cc b/views/event_gtk.cc
index c5970b7..cb76e76 100644
--- a/views/event_gtk.cc
+++ b/views/event_gtk.cc
@@ -10,9 +10,6 @@
namespace views {
-// TODO(jcampan): the same physical key can send different keyvals (ex: a or A).
-// In order for accelerators to work, we need to normalize that. The right
-// solution should probably to get the key-code out of the keystate.
KeyEvent::KeyEvent(GdkEventKey* event)
: Event(event->type == GDK_KEY_PRESS ?
Event::ET_KEY_PRESSED : Event::ET_KEY_RELEASED,
@@ -23,6 +20,7 @@ KeyEvent::KeyEvent(GdkEventKey* event)
message_flags_(0) {
}
+// static
int Event::GetFlagsFromGdkState(int state) {
int flags = 0;
if (state & GDK_CONTROL_MASK)