From Claus Scheiblauer, "in GraphicsWindowQt.cpp the GLWidget::keyReleaseEvent was implemented slightly different to the GLWidget::keyPressEvent, which caused the cursor keys values to be not correctly mapped from an QKeyEvent value to an osg key value when releasing a cursor key."
This commit is contained in:
@@ -270,7 +270,8 @@ void GLWidget::keyPressEvent( QKeyEvent* event )
|
||||
void GLWidget::keyReleaseEvent( QKeyEvent* event )
|
||||
{
|
||||
setKeyboardModifiers( event );
|
||||
_gw->getEventQueue()->keyRelease( (osgGA::GUIEventAdapter::KeySymbol) *(event->text().toAscii().data()) );
|
||||
int value = s_QtKeyboardMap.remapKey( event );
|
||||
_gw->getEventQueue()->keyRelease( value );
|
||||
|
||||
// this passes the event to the regular Qt key event processing,
|
||||
// among others, it closes popup windows on ESC and forwards the event to the parent widgets
|
||||
|
||||
Reference in New Issue
Block a user