Interacts with the application's orientation functionality.
This bridge is available on supported mobile touch platforms: Android and iOS.
#include <platform/YiApplicationOrientationBridge.h>
Public Member Functions | |
| virtual | ~CYIApplicationOrientationBridge () |
| virtual void | SetOrientation (YIViewProperty::Orientation eOrientation)=0 |
|
inlinevirtual |
|
pure virtual |
Sets the preferred orientation of the top-level view.
There is a difference in behaviour between iOS and Android when using the automatic settings (YIViewProperty::AUTO & YIViewProperty::AUTO_UPRIGHT). On iOS these two settings act by setting a mask of allowable orientations on the UI and do not alter the current orientation unless it is an orientation forbidden by the mask. On Android however, setting either of these will immediately turn control of the orientation to the device's sensor which may cause a rotation of the UI if its sensor reading does not match the current orientation.
On Android, this setting doesn't affect apps running in Multi-Window mode, however the setting will take effect once the app is maximized.