有没有办法根据安装应用程序的SDK版本使用不同的主题?
我问的原因是因为我希望一直支持SDK版本8,但对于那些拥有ICS的用户,我希望能够遵循ICS的设计标准并使用Holo主题.
我可以从程序中看到android中不同版本的不同布局我可以有一个文件夹值-v14,它将有一个theme.xml来覆盖主题声明.但是,如果我引用Theme.Holo,它将无法编译.我相信这是因为我在AndroidManifest.xml中有以下内容
任何指针都将非常感激.
更新: - 好的,这是我的文件: - AndroidManifest.xml:
android:icon="@drawable/icon"
android:label="@string/app_name"
android:name=".Refunder"
android:theme="@style/MainTheme"
>
RES /值/的themes.xml:
normal
15sp
RES /值-V11 /的themes.xml:
normal
15sp
当我这样做时,我在Eclipse中遇到编译错误,说:
error: Error retrieving parent for item: No resource found that matches the given name '@android:style/Theme.Holo'