如何使用 Ionic / Cordova 在 iOS 上启用多任务处理?

How to enable multitasking on iOS with Ionic / Cordova?

我一直在尝试在 iOS 上的 Ionic / Cordova 应用程序上启用多任务处理,但没有成功。

我已按照 [CB-9161] Support iPad multitasking in iOS 9 中的步骤操作:

The three rules are:

  1. Build your apps with the iOS 9 SDK
  2. Support all orientations
  3. Use Launch Storyboards

Fix for (1) is:

  1. Use Xcode 7 (Cordova always uses the current SDK)

Fix for (2) is:

  1. Click your Project icon in the Project Navigator
  2. Click on your Target
  3. Select the "General" tab
  4. Go to the "Deployment Info" section
  5. Select the "iPad" button segment
  6. For "Device Orientation", select all four checkboxes (Portrait, Upside Down, Landscape Left, Landscape Right)

Fix for (3) is:

  1. Add a new File: Launch Screen --> "Launch Screen.storyboard"
  2. Click your Project icon in the Project Navigator
  3. Click on your Target
  4. Select the "General" tab
  5. Go to the "App Icons and Launch Images" section
  6. Select "Launch Screen.storyboard" from the "Launch Screen File" dropdown

我可以在我的应用程序打开之前看到新的启动屏幕出现,但我仍然无法拆分视图。

供您参考,我正在使用 Xcode 8.2.1 构建 Mac。 所有 Device Orientation 框均已勾选,Requires full screen 为空白。

有什么想法或方向可以给我吗?

我刚发现问题:我正在使用 cordova-plugin-ipad-multitasking plugin to solve this issue。事实证明,这个插件阻止了多任务处理(我相信是通过强制 "Requires Full Screen" 选项)。删除插件解决了问题。