diff options
| author | Simon Tatham <anakin@pobox.com> | 2004-04-28 17:42:32 +0000 |
|---|---|---|
| committer | Simon Tatham <anakin@pobox.com> | 2004-04-28 17:42:32 +0000 |
| commit | e96f53452ac06e6b533a30d4caad30dd0dbe46fb (patch) | |
| tree | 967d1371d7d38d30924873fbcc88e8ac0fe400df /gtk.c | |
| parent | 3b1ec74d732399333f0b99a7af2a55cdd394a6cb (diff) | |
| download | puzzles-e96f53452ac06e6b533a30d4caad30dd0dbe46fb.zip puzzles-e96f53452ac06e6b533a30d4caad30dd0dbe46fb.tar.gz puzzles-e96f53452ac06e6b533a30d4caad30dd0dbe46fb.tar.bz2 puzzles-e96f53452ac06e6b533a30d4caad30dd0dbe46fb.tar.xz | |
Shift-click is equivalent to middle-click. This is mostly for
Windows users who may not have a middle button at all, but I've
replicated it in GTK to maintain cross-platform consistency.
[originally from svn r4166]
Diffstat (limited to 'gtk.c')
| -rw-r--r-- | gtk.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -181,10 +181,10 @@ static gint button_event(GtkWidget *widget, GdkEventButton *event, if (event->type != GDK_BUTTON_PRESS) return TRUE; - if (event->button == 1) - button = LEFT_BUTTON; - else if (event->button == 2) + if (event->button == 2 || (event->state & GDK_SHIFT_MASK)) button = MIDDLE_BUTTON; + else if (event->button == 1) + button = LEFT_BUTTON; else if (event->button == 3) button = RIGHT_BUTTON; else |