SetDeviceOrientation doesn't seem to be exposed to Lua

Is this a design decision or just something that was missed?

SetDeviceOrientation() should be call in the AppDelegate::applicationDidFinishLaunching()

Cool thanks. I take that as - it should never be called from Lua only from that method.

I think I’m still missing something with this.

In cocos2dx\HelloLua\Classes\AppDelegate.cpp in the applicationDidFinishLaunching function just before return true at the end of the function I added pDirector->setDeviceOrientation(kCCDeviceOrientationPortrait).

Then I run build_native.sh from cygwin and package in ecplise but when the apk runs on the device it’s still landscape. Any idea what might be the problem?