summaryrefslogtreecommitdiffstats
path: root/src/zoom-context.cpp
diff options
context:
space:
mode:
authorbulia byak <buliabyak@gmail.com>2007-07-29 19:18:19 +0000
committerbuliabyak <buliabyak@users.sourceforge.net>2007-07-29 19:18:19 +0000
commit3938195b9b488c13712db72f0c582d202bc4e669 (patch)
tree2e7b2bf59262c1cf6ee45cd6d201ca20353f7a98 /src/zoom-context.cpp
parentoptional panning by space (diff)
downloadinkscape-3938195b9b488c13712db72f0c582d202bc4e669.tar.gz
inkscape-3938195b9b488c13712db72f0c582d202bc4e669.zip
due to the order of processing events, we must disable lmb handling in children contexts so that parent event context can handle it for space panning
(bzr r3341)
Diffstat (limited to 'src/zoom-context.cpp')
-rw-r--r--src/zoom-context.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/zoom-context.cpp b/src/zoom-context.cpp
index d2b0d6849..4566a5ab0 100644
--- a/src/zoom-context.cpp
+++ b/src/zoom-context.cpp
@@ -124,7 +124,7 @@ static gint sp_zoom_context_root_handler(SPEventContext *event_context, GdkEvent
switch (event->type) {
case GDK_BUTTON_PRESS:
- if (event->button.button == 1) {
+ if (event->button.button == 1 && !event_context->space_panning) {
// save drag origin
xp = (gint) event->button.x;
yp = (gint) event->button.y;
@@ -141,7 +141,7 @@ static gint sp_zoom_context_root_handler(SPEventContext *event_context, GdkEvent
break;
case GDK_MOTION_NOTIFY:
- if (event->motion.state & GDK_BUTTON1_MASK) {
+ if (event->motion.state & GDK_BUTTON1_MASK && !event_context->space_panning) {
ret = TRUE;
if ( within_tolerance
@@ -161,7 +161,7 @@ static gint sp_zoom_context_root_handler(SPEventContext *event_context, GdkEvent
break;
case GDK_BUTTON_RELEASE:
- if ( event->button.button == 1 ) {
+ if ( event->button.button == 1 && !event_context->space_panning) {
NR::Maybe<NR::Rect> const b = Inkscape::Rubberband::get()->getRectangle();
if (b && !within_tolerance) {
desktop->set_display_area(*b, 10);