[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [krita/kazakov/svg-loading] plugins/tools/defaulttool/defaulttool: Don't snap to the resized shape w
From:       Dmitry Kazakov <null () kde ! org>
Date:       2017-02-06 10:23:08
Message-ID: E1cagRw-0000uv-0W () code ! kde ! org
[Download RAW message or body]

Git commit d06cd3af0aec71124b8e3230b83f13aff7a5f730 by Dmitry Kazakov.
Committed on 06/02/2017 at 10:22.
Pushed by dkazakov into branch 'kazakov/svg-loading'.

Don't snap to the resized shape when resizing it

M  +1    -1    plugins/tools/defaulttool/defaulttool/ShapeMoveStrategy.cpp
M  +1    -0    plugins/tools/defaulttool/defaulttool/ShapeResizeStrategy.cpp

https://commits.kde.org/krita/d06cd3af0aec71124b8e3230b83f13aff7a5f730

diff --git a/plugins/tools/defaulttool/defaulttool/ShapeMoveStrategy.cpp \
b/plugins/tools/defaulttool/defaulttool/ShapeMoveStrategy.cpp index \
                fb5609d9f85..6c6e3242554 100644
--- a/plugins/tools/defaulttool/defaulttool/ShapeMoveStrategy.cpp
+++ b/plugins/tools/defaulttool/defaulttool/ShapeMoveStrategy.cpp
@@ -58,7 +58,7 @@ ShapeMoveStrategy::ShapeMoveStrategy(KoToolBase *tool, const \
QPointF &clicked)  
     KoSelection *selection = m_canvas->shapeManager()->selection();
     m_initialOffset = selection->absolutePosition(anchor) - m_start;
-    m_canvas->snapGuide()->setIgnoredShapes(KoShape::linearizeSubtree(selection->selectedShapes()));
 +    m_canvas->snapGuide()->setIgnoredShapes(KoShape::linearizeSubtree(m_selectedShapes));
  
     tool->setStatusText(i18n("Press Shift to hold x- or y-position."));
 }
diff --git a/plugins/tools/defaulttool/defaulttool/ShapeResizeStrategy.cpp \
b/plugins/tools/defaulttool/defaulttool/ShapeResizeStrategy.cpp index \
                5354935d875..244cc55fff6 100644
--- a/plugins/tools/defaulttool/defaulttool/ShapeResizeStrategy.cpp
+++ b/plugins/tools/defaulttool/defaulttool/ShapeResizeStrategy.cpp
@@ -109,6 +109,7 @@ ShapeResizeStrategy::ShapeResizeStrategy(KoToolBase *tool, const \
QPointF &clicke  }
 
     tool->setStatusText(i18n("Press CTRL to resize from center."));
+    tool->canvas()->snapGuide()->setIgnoredShapes(KoShape::linearizeSubtree(m_selectedShapes));
  }
 
 ShapeResizeStrategy::~ShapeResizeStrategy()


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic