PDA

View Full Version : Fullscreen, but not standalone?



Luc
6 Sep 2011, 11:37 PM
Hi all,

I would like my Sencha Touch app to use the full browser screen, but it should not start up as a standalone app (apple-mobile-web-app-capable content="yes") when started from the Homescreen. It should start up in Safari.

Using fullscreen: true nicely uses the full browser screen, but it also injects the apple-mobile-web-app-capable meta tag, whichs makes it a standalone app.

As a workaround, I intercepted calls to Ext.addMetaTags and prevented the apple-mobile-web-app-capable content from being created. Is there a better way?

Thanks!

deanmas
26 Nov 2011, 6:31 AM
Can you share the code for that?

I remove the meta tag inside my launch method - the drawback is it won't work if the user bookmarks it before app is properly launched which I think is unlikely. Here is the code:


var standalone = Ext.select('meta[name="apple-mobile-web-app-capable"]');
if (standalone.elements.length > 0) {
Ext.removeNode(standalone.elements[0]);
}