[gtk+/wip/mir2: 216/232] mir: compute the modifiers using the saved button_state on key events
- From: William Hua <williamhua src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/mir2: 216/232] mir: compute the modifiers using the saved button_state on key events
- Date: Mon, 5 Jan 2015 15:14:16 +0000 (UTC)
commit 8d57822a20ccb4fe2b26e11e09d6e25e6243ae1d
Author: Marco Trevisan (TreviƱo) <mail 3v1n0 net>
Date: Tue Dec 2 16:27:28 2014 +0100
mir: compute the modifiers using the saved button_state on key events
gdk/mir/gdkmireventsource.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/gdk/mir/gdkmireventsource.c b/gdk/mir/gdkmireventsource.c
index 701f394..13f09bb 100644
--- a/gdk/mir/gdkmireventsource.c
+++ b/gdk/mir/gdkmireventsource.c
@@ -258,10 +258,13 @@ get_modifier_state (unsigned int modifiers, unsigned int button_state)
static void
handle_key_event (GdkWindow *window, const MirKeyEvent *event)
{
+ GdkMirWindowImpl *impl = GDK_MIR_WINDOW_IMPL (window->impl);
guint modifier_state;
+ MirMotionButton button_state;
gboolean is_modifier = FALSE;
- modifier_state = get_modifier_state (event->modifiers, 0); // FIXME: Need to track button state
+ _gdk_mir_window_impl_get_cursor_state (impl, NULL, NULL, NULL, &button_state);
+ modifier_state = get_modifier_state (event->modifiers, button_state);
switch (event->action)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]