Reputation: 2718
Im trying to remove the titlebar at the top of my app.
I know this can be done by adding, @android:style/Theme.NoTitleBar
to the manifest. The thing is that this makes the Holo theme disappear on 3.0+ devices.
Are there anyway I can remove the titlebar and keep the orginal theme?
-EDIT-
Unforiunally this line @android:style/Theme.Holo.NoActionBar
requires api level above 11.
Upvotes: 0
Views: 2207
Reputation: 5374
You can specify different default themes for different API levels.
In Android you have the directories values-v11
and values
. The first one is for all Android 3.0 and above (if no other one with higher version is specified). The second is the default one.
In the styles.xml
of values-v11
you define:
<style name="AppBaseTheme" parent="android:Theme.Holo.NoActionBar"></style>
and in the styles.xml
of values
:
<style name="AppBaseTheme" parent="android:Theme.NoTitleBar"></style>
If you put android:theme="@style/AppBaseTheme"
in the <application>
tag of the manifest you should keep the Holo theme on 3.0+ devices.
Upvotes: 1