summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2a0f3e1)
raw | patch | inline | side by side (parent: 2a0f3e1)
author | dvlierop2 <dvlierop2@users.sourceforge.net> | |
Tue, 21 Apr 2009 19:10:22 +0000 (19:10 +0000) | ||
committer | dvlierop2 <dvlierop2@users.sourceforge.net> | |
Tue, 21 Apr 2009 19:10:22 +0000 (19:10 +0000) |
src/seltrans.cpp | patch | blob | history |
diff --git a/src/seltrans.cpp b/src/seltrans.cpp
index 816a471cf4386f8e12c98c87c95f1e0215dea98d..64f7d3cdcf526f602883d56e188d4a90d29311a1 100644 (file)
--- a/src/seltrans.cpp
+++ b/src/seltrans.cpp
m.setup(_desktop, true, _items_const);
m.freeSnapReturnByRef(SnapPreferences::SNAPPOINT_NODE, dxy, Inkscape::SNAPSOURCE_UNDEFINED);
- } else if (!shift) {
+ } else if (shift) {
+ if (control) { // shift & control: constrained movement without snapping
+ if (fabs(dxy[Geom::X]) > fabs(dxy[Geom::Y])) {
+ dxy[Geom::Y] = 0;
+ } else {
+ dxy[Geom::X] = 0;
+ }
+ }
+ } else { //!shift: with snapping
/* We're snapping to things, possibly with a constraint to horizontal or
** vertical movement. Obtain a list of possible translations and then
/* This will be our list of possible translations */
std::list<Inkscape::SnappedPoint> s;
- if (control) {
+ if (control) { // constrained movement with snapping
/* Snap to things, and also constrain to horizontal or vertical movement */
_point,
Inkscape::Snapper::ConstraintLine(component_vectors[dim]),
dxy));
- } else {
+ } else { // !control
// Let's leave this timer code here for a while. I'll probably need it in the near future (Diederik van Lierop)
/* GTimeVal starttime;