Hi,
I am using the Key events in the latest SDK to try go back to the previous screen in the app that I am building. I am using the Director class to do a changescene when the back button is pressed.
But when The previous screen is getting displayerd all the images are getting distored and appear rectangular in shape.
The image of the problem is given here
https://picasaweb.google.com/111538299285179791683/August62011#
Is there anything specific that needs to be done to handle images when capturing the harware key press on Android phones.
The code that I am using is given below
[lua] local function onKeyEvent( event )
if event.phase == “up” and event.keyName == “back” then
director:changeScene( “Menu” )
end
return true
end
– Add the key callback
Runtime:addEventListener( “key”, onKeyEvent );
[import]uid: 50371 topic_id: 13411 reply_id: 313411[/import]