diff --git a/src/osgViewer/CompositeViewer.cpp b/src/osgViewer/CompositeViewer.cpp index 5bb9eff22..85045e898 100644 --- a/src/osgViewer/CompositeViewer.cpp +++ b/src/osgViewer/CompositeViewer.cpp @@ -1120,6 +1120,10 @@ void CompositeViewer::eventTraversal() { osgGA::GUIEventAdapter* event = (*itr)->asGUIEventAdapter(); if (!event) continue; + + // ignore event if it's already been handled. + if (event->getHandled()) continue; + switch(event->getEventType()) { case(osgGA::GUIEventAdapter::KEYUP): diff --git a/src/osgViewer/Viewer.cpp b/src/osgViewer/Viewer.cpp index 3ab9f63b0..613e21b9f 100644 --- a/src/osgViewer/Viewer.cpp +++ b/src/osgViewer/Viewer.cpp @@ -989,6 +989,10 @@ void Viewer::eventTraversal() { osgGA::GUIEventAdapter* event = (*itr)->asGUIEventAdapter(); if (!event) continue; + + // ignore event if it's already been handled. + if (event->getHandled()) continue; + switch(event->getEventType()) { case(osgGA::GUIEventAdapter::KEYUP):