Reputation: 11005
I create new Tabbar based project in Corona. Then I change file build.settings to support landscape orientation
orientation = {
default = "portrait",
supported = { "portrait","landscapeLeft","landscapeRight" }
},
Thanks!
Upvotes: 2
Views: 834
Reputation: 9140
The selected answer is not entirely correct. You should be listening to event.resize and not event.orientation.
From the orientation docs:
However, for apps with multiple supported orientations, the orientation event should not be used to re-layout the UI — instead, the resize event should be used.
Upvotes: 1
Reputation: 2271
I don't think Corona SDK gives you autoresize out of the box. I think you are supposed to listen for the 'orientation' event on the Runtime object to be notified when the device is rotated, then reposition your controls accordingly.
See the Events and Listeners section of the Corona SDK documentation (search for 'orientation' on that page).
Upvotes: 1