[gtk+/wip/mir2] mir: compute the modifiers using the saved button_state on key events
- From: Marco Trevisan <marcotrevi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/mir2] mir: compute the modifiers using the saved button_state on key events
- Date: Tue, 2 Dec 2014 15:27:53 +0000 (UTC)
commit 6db489dc399bfb1fb0fc206d0bd206ac3468c3c7
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]