我正在嘗試在 ios 的 flutter 應用程式上啟用倒置縱向模式。應用程式中啟用了所有方向:
SystemChrome.setPreferredOrientations([
DeviceOrientation.portraitUp,
DeviceOrientation.portraitDown,
DeviceOrientation.landscapeRight,
DeviceOrientation.landscapeLeft,
]);
所有方向也通過 Xcode 在 ios 專案設定上啟用:
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeRight</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
</array>
出于某種原因,iOS 顛倒縱向模式不起作用。任何關于可能出錯的想法都受到高度贊賞
uj5u.com熱心網友回復:
蘋果檔案
所有 iPadOS 設備都支持 PortraitUpsideDown 方向。最佳做法是為 iPad 習慣用法啟用它。沒有主頁按鈕的 iOS 設備(例如 iPhone 12)不支持此方向。對于 iPhone 習慣用法,您應該完全禁用它。
您是否在合適的 ios 設備上測驗過此功能?
轉載請註明出處,本文鏈接:https://www.uj5u.com/ruanti/359626.html
下一篇:Flutter對話框與MVC
