This API is called using wx.onDeviceOrientationChange(function listener).
Property | Type | Description |
value | string | The new screen orientation. landscape: Landscape mode with the HOME button on the right. landscapeReverse: Landscape mode with the HOME button on the left. |
This API is called using wx.offDeviceOrientationChange(function listener).
const listener = function (res) { console.log(res) }wx.onDeviceOrientationChange(listener)wx.offDeviceOrientationChange(listener) // Must pass the same function object used in onDeviceOrientationChange
Feedback