How to edit theme.xml on Titanium?

1

I need to remove actionBar from my project and the best way I found it was to edit theme.xml. However, when I edit it, I can not save it and soon, my actionBar is still active. I tried to put the line of code (below) but when emulated, my windows do not load. I tried writing at the beginning and end of the project, without success. $ .index.activity.actionBar.hide ();

    
asked by anonymous 16.07.2015 / 18:54

1 answer

0

After editing the theme.xml, you need to reference it in tiapp.xml, inside the manifest tag, eg

<android xmlns:android="http://schemas.android.com/apk/res/android">
    <manifest>
       <application android:theme="@style/nomeDoTema"/>
    </manifest>
</android>

However, in the latest versions of Titanium (from 4.2.0), you can remove ActionBar from a Window using the theme property:

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

The full documentation you can find here: link

    
28.04.2016 / 23:19