From 764ce362f350a49e9bfa48b46897d799d34fae88 Mon Sep 17 00:00:00 2001 From: Pietro Gagliardi Date: Thu, 14 Aug 2014 23:28:22 -0400 Subject: Finally removed the TODO for buttons > 3 in GTK+ Areas (alas, bad end). --- redo/area_unix.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'redo/area_unix.go') diff --git a/redo/area_unix.go b/redo/area_unix.go index 7c3829e..5875b11 100644 --- a/redo/area_unix.go +++ b/redo/area_unix.go @@ -182,7 +182,8 @@ func finishMouseEvent(widget *C.GtkWidget, data C.gpointer, me MouseEvent, mb ui if mb != 3 && (state&C.GDK_BUTTON3_MASK) != 0 { me.Held = append(me.Held, 3) } - // don't check GDK_BUTTON4_MASK or GDK_BUTTON5_MASK because those are for the scrolling buttons mentioned above; there doesn't seem to be a way to detect higher buttons... (TODO) + // don't check GDK_BUTTON4_MASK or GDK_BUTTON5_MASK because those are for the scrolling buttons mentioned above + // GDK expressly does not support any more buttons in the GdkModifierType; see https://git.gnome.org/browse/gtk+/tree/gdk/x11/gdkdevice-xi2.c#n763 (thanks mclasen in irc.gimp.net/#gtk+) me.Pos = image.Pt(int(x), int(y)) C.gtk_widget_get_size_request(widget, &areawidth, &areaheight) if !me.Pos.In(image.Rect(0, 0, int(areawidth), int(areaheight))) { // outside the actual Area; no event -- cgit v1.2.3