3
votes

I think i tried thousands of combinations, but after hours and hours i did not get any results. I'm trying to hide the STATUS BAR and the NAVIGATION BAR.

This is the actual result (only the splashscreen is ok) :

enter image description here enter image description here

I read several tickets / questions.

Solutions I've tried

app.js

win.fullscreen = true / false;
win.navBarHidden = true / false; 

tiapp.xml

<fullscreen>true/false</fullscreen>
<navbar-hidden>false/false</navbar-hidden>
<statusbar-hidden>true/false</statusbar-hidden>

tiapp.xml (section <android xmlns:android="http://schemas.android.com/apk/res/android">)

<android xmlns:android="http://schemas.android.com/apk/res/android">
    <manifest>
        <application android:theme="@style/Theme.AppCompat.Translucent.NoTitleBar.Fullscreen"/>
    </manifest>
</android>
1

1 Answers

3
votes

There are some build-in themes you can use on window level to hide the navigation/status bar on Android.

https://wiki.appcelerator.org/display/guides2/Android+Themes

So.. you can set it like this (in classic):

var win = Ti.UI.createWindow({
    theme: "Theme.AppCompat.Translucent.NoTitleBar.Fullscreen"
});

In Alloy you can set it globally easily by doing this in app.tss:

'Window': {
     theme: "Theme.AppCompat.Translucent.NoTitleBar.Fullscreen"
}