flutter 应用程序没有占据 ipad 屏幕的全宽?

flutter app not taking full width of ipad screen?

在 android 和 iPhone 上启动该应用程序运行良好,而在 iPad 上启动它时该应用程序意外地没有占用屏幕的整个宽度!

尝试编辑 Main.storyboard <view> 宽度但没有任何反应

<view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
    <rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
    <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
    <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
</view>

您需要注册您的应用程序Universal

Go to Runner > Target > Deployment info

在最新的 XCode 版本中,它不再与已接受的答案相同,现在您可以这样做。

  1. 转到 Runner/BuildSettings 并找到 Deployment

  2. 点击 Targeted Device Families 旁边的 iPhone,然后点击 other

  3. 在框中添加 2 并按 enter

就是这样。现在看起来像这样: