Cordova and iOS Split Screen

543 views
Skip to first unread message

James Henderson

unread,
Jan 17, 2017, 6:28:51 AM1/17/17
to phon...@googlegroups.com
I am trying to get the iOS Split Screen feature working - I realise it is only certain devices (eg iPad Air 2 etc).

In xCode (in the General Tab), using a clean/default Cordova project, it has "CDVLaunchScreen" in the dropdown for "App Icons and Launch Images".

I have added the cordova plugin: cordova-plugin-splashscreen and added these in iOS section of config.xml (and they load are working):

<splash src="res/screen/ios/Default@2x~universal~anyany.png" />
<splash src="res/screen/ios/Default@2x~universal~comany.png" />

But all I get is the iOS search panel, but I want the option to open an email App, or Messages etc.

Any help greatly appreciated

Kerri Shotts

unread,
Jan 17, 2017, 10:51:09 PM1/17/17
to phonegap
Hi James,

Make sure that:
  • you are using cordo...@4.3.1
  • your app supports all orientations (and I mean all, including upside-down portrait)
  • you have not opted out of split multitasking (UIRequiresFullScreen should be NO [false] if present in your info plist)

James Henderson

unread,
Jan 19, 2017, 12:12:07 PM1/19/17
to phon...@googlegroups.com
Thanks Kerri,

Really helpful advice! I have since done some successful testing, but there is still a minor Cordova problem. If you create a new Cordova project (latest CLI etc), then open it up in xCode, sign it, check the iPad has all 4 orientations, turn off 'Requires Full Screen' tick box, and specify CDVLaunchScreen.storyboard in the “App Icons and Launch Images” Launch Screen File, and then run it from xCode - it works fine, but when I run it from Cordova CLI, the *-Info.plist gets written over and the App stops appearing in the side area. Hope this is helpful?

Best regards,

James



--
-- You received this message because you are subscribed to the Google
Groups "phonegap" group.
To post to this group, send email to phon...@googlegroups.com
To unsubscribe from this group, send email to
phonegap+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/phonegap?hl=en?hl=en
 
For more info on PhoneGap or to download the code go to www.phonegap.com
---
You received this message because you are subscribed to the Google Groups "phonegap" group.
To unsubscribe from this group and stop receiving emails from it, send an email to phonegap+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Kerri Shotts

unread,
Jan 19, 2017, 2:42:22 PM1/19/17
to phonegap
Don't make any changes in Xcode, instead:

  • Use build.json for signing
  • Specify "all" for your Orientation preference (that should allow all four, IIRC)
  • Change requires full screen via edit-config (I think the following should work):
<edit-config target="*-Info.plist" parent="UIRequiresFullScreen" mode="overwrite">
    <false/>
</edit-config>
I've been meaning to build a simple plugin that takes care of the latter two points automatically, but haven't had the time yet.

Hope that helps.

Kerri Shotts

unread,
Jan 20, 2017, 9:02:12 PM1/20/17
to phonegap
Turns out there is a plugin already for setting the latter two options! See https://github.com/rafelbev/cordova-plugin-ipad-multitasking

Ralpharoo

unread,
Aug 1, 2017, 11:20:21 AM8/1/17
to phonegap
Hey Kerri,

Just realized that plugin does not do what you think it does. It seems to be setting UIRequiresFullScreen to YES which opts out of multitasking.

Cheers,

Ralph
Reply all
Reply to author
Forward
0 new messages