【发布时间】:2014-07-28 09:10:51
【问题描述】:
我使用 Titanium SDK 3.3.0 并希望使用主题解决方案禁用 Android 中的“新”ActionBar。 除了想使用 9-Patch-Image 作为启动屏幕/加载屏幕。
参考文档和指南: http://docs.appcelerator.com/titanium/3.0/#!/guide/Android_Action_Bar http://docs.appcelerator.com/titanium/3.0/#!/guide/Android_Themes
我有以下项目设置:
用于启动画面的文件:
/platform/android/res/drawable-ldpi/splash.9.png
/platform/android/res/drawable-mdpi/splash.9.png
/platform/android/res/drawable-hdpi/splash.9.png
/platform/android/res/drawable-xhdpi/splash.9.png
主题文件:/platform/android/res/values/gsgptheme.xml
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="Theme.GSGP" parent="Theme.AppCompat">
<!-- Depending on the parent theme, this may be called android:windowActionBar instead of windowActionBar -->
<item name="android:windowActionBar">false</item>
<item name="android:windowBackground">@drawable/splash</item>
<item name="android:windowNoTitle">true</item>
</style>
</resources>
tiapp.xml:
<android xmlns:android="http://schemas.android.com/apk/res/android">
<manifest android:installLocation="auto"
android:versionCode="21" android:versionName="3.1.1">
<application android:theme="@style/Theme.GSGP"/>
<uses-sdk android:minSdkVersion="11" android:targetSdkVersion="14"/>
<supports-screens android:anyDensity="false"/>
</manifest>
</android>
问题是:Titanium 似乎没有加载我的主题。在启动时,我看到默认的加载屏幕并且仍然有一个操作栏。谁能看到我的错误?
【问题讨论】:
标签: android-actionbar titanium themes