From Alexander Sinditskiy, "I just noticed that Dragger allways handle events even when

handle(const PointerInfo&, const osgGA::GUIEventAdapter&, osgGA::GUIActionAdapter&)
returns false.I think it is not correct...i think handled should be changed only when it is really handled."
This commit is contained in:
Robert Osfield 2013-05-21 09:48:16 +00:00
parent 9f66a10aa2
commit 255432f76b

View File

@ -403,9 +403,11 @@ bool Dragger::handle(const osgGA::GUIEventAdapter& ea, osgGA::GUIActionAdapter&
_pointer.setCamera(rootCamera);
_pointer.setMousePosition(ea.getX(), ea.getY());
dragger->handle(_pointer, ea, aa);
dragger->setDraggerActive(true);
handled = true;
if(dragger->handle(_pointer, ea, aa))
{
dragger->setDraggerActive(true);
handled = true;
}
}
}
}
@ -421,9 +423,10 @@ bool Dragger::handle(const osgGA::GUIEventAdapter& ea, osgGA::GUIActionAdapter&
// _pointer.setCamera(view->getCamera());
_pointer.setMousePosition(ea.getX(), ea.getY());
handle(_pointer, ea, aa);
handled = true;
if(handle(_pointer, ea, aa))
{
handled = true;
}
}
break;
}