Is it possible to hide the safari address bar in iOS10?

Discussion and feedback on Construct 2

Post » Mon Oct 31, 2016 5:33 pm

I've tried requesting fullscreen, but that doesn't seem to work. Why was this feature removed?
B
68
S
24
G
11
Posts: 452
Reputation: 12,238

Post » Mon Oct 31, 2016 11:18 pm

It wasn't removed, iOS10 changed the way Safari responds to certain feature calls.

You have to use this instead on the first layout:

Browser -> Execute Javascript = "StatusBar.hide();"

Then you can request Fullscreen.
B
70
S
24
G
19
Posts: 1,757
Reputation: 17,614

Post » Mon Oct 31, 2016 11:37 pm

Thanks @Silverforce I will try it!
B
86
S
25
G
11
Posts: 652
Reputation: 11,045

Post » Mon Oct 31, 2016 11:57 pm

Silverforce wrote:It wasn't removed, iOS10 changed the way Safari responds to certain feature calls.

You have to use this instead on the first layout:

Browser -> Execute Javascript = "StatusBar.hide();"

Then you can request Fullscreen.


Thanks! I just tried on my device and it didn't work unfortunately. Can anyone comment if it is an apple restriction?
B
68
S
24
G
11
Posts: 452
Reputation: 12,238

Post » Tue Nov 01, 2016 10:05 pm

I've talked to another developer and he tells me safari on ios doesn't respond well to js. That would explain why this doesn't work here. Is there any way in construct 2 to do this? Perhaps a way outside of C2 with custom code on the game page...
B
68
S
24
G
11
Posts: 452
Reputation: 12,238

Post » Tue Nov 01, 2016 11:16 pm

Which export tool are you using? Intel XDK, or something else? It does work. You need the external plugin for StatusBar.
ImageImageImage
B
71
S
21
G
220
Posts: 3,648
Reputation: 123,725

Post » Wed Nov 02, 2016 12:53 am

Looks like there was a misunderstanding here, I'm just accessing the game through the safari webpage. It's exported as an html5 website.
B
68
S
24
G
11
Posts: 452
Reputation: 12,238

Post » Wed Nov 02, 2016 1:52 am

https://www.scirra.com/manual/110/browser
Request fullscreen
Request that the browser enter fullscreen mode. Note the browser may ignore this request unless the action is in a user-initiated event, such as a mouse click, key press, touch event or button press. The fullscreen modes that can be entered correspond to the Fullscreen in browser project property. For more information see supporting multiple screen sizes. Note not all platforms support requesting fullscreen - use the Supports requesting fullscreen condition to check for availability.
ImageImageImage
B
71
S
21
G
220
Posts: 3,648
Reputation: 123,725

Post » Wed Nov 02, 2016 2:26 am

blackhornet wrote:https://www.scirra.com/manual/110/browser
Request fullscreen
Request that the browser enter fullscreen mode. Note the browser may ignore this request unless the action is in a user-initiated event, such as a mouse click, key press, touch event or button press. The fullscreen modes that can be entered correspond to the Fullscreen in browser project property. For more information see supporting multiple screen sizes. Note not all platforms support requesting fullscreen - use the Supports requesting fullscreen condition to check for availability.


That's what I've been using, I may be remembering incorrectly but I believe there used to be an event to hide browser url bar. Maybe it has been replaced by this. I was trying it at the start of layout so I tried making it a touch reacted event but that didn't seem to work either. So it appears the answer to my question is no. :cry:
B
68
S
24
G
11
Posts: 452
Reputation: 12,238

Post » Wed Nov 02, 2016 3:46 am

What does "Supports requesting fullscreen" return, as mentioned?
ImageImageImage
B
71
S
21
G
220
Posts: 3,648
Reputation: 123,725

Next

Return to Construct 2 General

Who is online

Users browsing this forum: tarek2 and 6 guests