Hi Stephan, Thanks for the changes. Do you feel they are ready to merge?
Robert. On Fri, Jan 28, 2011 at 11:07 AM, Stephan Maximilian Huber <[email protected]> wrote: > Hi all, > > I adapted the Cocoa implementation so that it reports the unmodified key > and the modified key as requested. Can other OS X developers please test > the attached file, to make sure it works for everybody? > > I fixed the problem with the caps-lock-key, too. > > P.S. as reported before the default-font is currently broken, see > attached screenshot. > > cheers, > Stephan > > > Am 27.01.11 17:40, schrieb Robert Osfield: >> Hi OSX dev's, >> >> This afternoon I merged a submission from Alexander Sinditskiy, that >> addressed a limitation in osgGA::GUIEventAdapter where the getKey() >> method would return only the modified variation of the keycode that >> was pressed - so this would be Ctrl-C, 'C' or 'c', and if your you >> didn't want to worry about the modified key status you'd have to >> handle each of these cases in your event code. >> >> The way that Alexander addressed this was to add a new UnmodifiedKey >> property to GUIEventAdapter, with support added to the >> osgGA::EventQueue as well as the X11 and Win32 implementations found >> in GraphicsWindowX11.cpp and GraphicsWindowWin32.cpp. Alexander and >> his colleagues don't have access to OSX so couldn't add the required >> support into GraphicsWindowCocoa/Carbon so for now you'll just get a 0 >> for the UnmofidiedKey. >> >> Now this won't affect most apps as they won't yet be using the >> UnmodifiedKey property, but osgkeyboard has now been modified to use >> the UnmodifiedKey property as this illustrates it's usage and also >> simplifies the example as it no longer needs to doing multiple >> mappings to handle upper and lower case letters. However, osgkeyboard >> will now just get a 0 for UnmodifiedKey so the keys on screen won't >> toggle on/off correctly. At least this is what I'm expecting - I >> don't have on OSX box in front of me so I can't test this. >> >> Could OSX users try out OSG in svn/trunk and run osgkeyboard and see >> how things behave and then have a look into the possibility of >> providing the UmodifiedKey property as GraphicsWindowWin32.cpp and >> GraphicsWindowX11.cpp now do. The unmodified keys now map the 'A' and >> 'a' to be 'a', X11 is already uses this convention while Win32 have >> 'A' as the unmodified state, but Alexander's revision addresses this >> so both produce an GUIEventAdapter::KEY_A which is mapped to 'a'. OSX >> will need to use the same convention. >> >> Thanks in advance with any help you can provide in adding this >> functionality to OSX. >> >> Cheers, >> Robert. >> _______________________________________________ >> osg-users mailing list >> [email protected] >> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

