diff options
author | Neil <nyamatongwe@gmail.com> | 2013-08-15 15:13:15 +1000 |
---|---|---|
committer | Neil <nyamatongwe@gmail.com> | 2013-08-15 15:13:15 +1000 |
commit | 2b08c6ee48f984b99165a156690dfcf4c67fea21 (patch) | |
tree | 87a806590e7d7e4a4aee9ebdaa97ab41fa022dc1 /gtk/ScintillaGTK.cxx | |
parent | a499680e07e1eeb55d23bbf1f61dde535d5beb78 (diff) | |
download | scintilla-mirror-2b08c6ee48f984b99165a156690dfcf4c67fea21.tar.gz |
Feature: [feature-requests:#1007]. Option to allow mouse selection to
switch to rectangular by pressing Alt after start of gesture.
From Neomi.
Diffstat (limited to 'gtk/ScintillaGTK.cxx')
-rw-r--r-- | gtk/ScintillaGTK.cxx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gtk/ScintillaGTK.cxx b/gtk/ScintillaGTK.cxx index db9e1ea19..25d61d9f2 100644 --- a/gtk/ScintillaGTK.cxx +++ b/gtk/ScintillaGTK.cxx @@ -1962,7 +1962,10 @@ gint ScintillaGTK::Motion(GtkWidget *widget, GdkEventMotion *event) { //Platform::DebugPrintf("Move %x %x %d %c %d %d\n", // sciThis,event->window,event->time,event->is_hint? 'h' :'.', x, y); Point pt(x, y); - sciThis->ButtonMove(pt); + int modifiers = ((event->state & GDK_SHIFT_MASK) != 0 ? SCI_SHIFT : 0) | + ((event->state & GDK_CONTROL_MASK) != 0 ? SCI_CTRL : 0) | + ((event->state & modifierTranslated(sciThis->rectangularSelectionModifier)) != 0 ? SCI_ALT : 0); + sciThis->ButtonMoveWithModifiers(pt, modifiers); } catch (...) { sciThis->errorStatus = SC_STATUS_FAILURE; } |