+ implement alternative zooming for Inventor style

+ proper handling of space navigator events
+ fix bug when assigning user-defined shortcuts

git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5369 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
This commit is contained in:
wmayer
2011-12-31 17:51:41 +00:00
parent 50ae86e595
commit ac4b6a4d91
3 changed files with 8 additions and 3 deletions

View File

@@ -226,6 +226,7 @@ SbBool InventorNavigationStyle::processSoEvent(const SoEvent * const ev)
}
}
}
this->button2down = press;
break;
case SoMouseButtonEvent::BUTTON3:
if (press) {
@@ -306,10 +307,12 @@ SbBool InventorNavigationStyle::processSoEvent(const SoEvent * const ev)
BUTTON1DOWN = 1 << 0,
BUTTON3DOWN = 1 << 1,
CTRLDOWN = 1 << 2,
SHIFTDOWN = 1 << 3
SHIFTDOWN = 1 << 3,
BUTTON2DOWN = 1 << 4
};
unsigned int combo =
(this->button1down ? BUTTON1DOWN : 0) |
(this->button2down ? BUTTON2DOWN : 0) |
(this->button3down ? BUTTON3DOWN : 0) |
(this->ctrldown ? CTRLDOWN : 0) |
(this->shiftdown ? SHIFTDOWN : 0);
@@ -339,6 +342,7 @@ SbBool InventorNavigationStyle::processSoEvent(const SoEvent * const ev)
break;
case BUTTON1DOWN|BUTTON3DOWN:
case CTRLDOWN|BUTTON3DOWN:
case CTRLDOWN|SHIFTDOWN|BUTTON2DOWN:
newmode = NavigationStyle::ZOOMING;
break;