0000712: Cad Navigation Zoom with Ctrl + causes shapes to pan off screen

This commit is contained in:
wmayer
2012-05-21 18:27:30 +02:00
parent a3bef0be95
commit e07b82719f
3 changed files with 15 additions and 13 deletions

View File

@@ -721,6 +721,16 @@ void NavigationStyle::zoomByCursor(const SbVec2f & thispos, const SbVec2f & prev
zoom(viewer->getCamera(), (thispos[1] - prevpos[1]) * 10.0f/*20.0f*/);
}
void NavigationStyle::zoomIn()
{
zoom(viewer->getCamera(), -this->zoomStep);
}
void NavigationStyle::zoomOut()
{
zoom(viewer->getCamera(), this->zoomStep);
}
void NavigationStyle::doZoom(SoCamera* camera, SbBool forward, const SbVec2f& pos)
{
SbBool zoomAtCur = this->zoomAtCursor;