Hi,
AFAIK alt must be pressed with some other key before you'll get an event.
jp
On 05/08/2011 09:59, ramy panda wrote:
Hi,
In my codes, i rewrite keyPressEvent function like below:
void AdapterWidget::keyPressEvent( QKeyEvent* event )
{
_gw->getEventQueue()->keyPress( (osgGA::GUIEventAdapter::KeySymbol)
*(event->text().toAscii().data() ) );
}
In my osg codes, i write like this:
bool ManipulatorEventHandler::handle(const osgGA::GUIEventAdapter& ea,
osgGA::GUIActionAdapter& aa,
osg::Object*, osg::NodeVisitor*)
{
bool alt = (ea.getModKeyMask()&
(osgGA::GUIEventAdapter::MODKEY_LEFT_ALT|osgGA::GUIEventAdapter::MODKEY_RIGHT_ALT))
!= 0;
if (alt) return false;
if (ea.getEventType() == osgGA::GUIEventAdapter::KEYDOWN)
{
switch (ea.getKey())
{
case 'r': resetTransform(); break;
}
}
return true;
}
but when i press alt key there is no reponse in my application. I need a help
in an emergency and i'm waiting answer online. Thanks very much.
Thank you!
Cheers,
ramy
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=41868#41868
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
--
This message is subject to the CSIR's copyright terms and conditions, e-mail legal notice, and implemented Open Document Format (ODF) standard.
The full disclaimer details can be found at http://www.csir.co.za/disclaimer.html.
This message has been scanned for viruses and dangerous content by MailScanner,
and is believed to be clean.
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org