福尔摩斯动作条风格缺失 [英] Sherlock actionbar missing styles

查看:125
本文介绍了福尔摩斯动作条风格缺失的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想实现大侦探动作条,而是因为它根本不存在,我无法设置正确的主题清单。本教程说要放机器人:主题=@风格/ Theme.Sherlock,但我没有这样的选择,为什么呢?
我正确添加福尔摩斯库我的项目。

I'm trying to implement sherlock actionbar but i can't set the right theme in the manifest because it simply doesn't exists. the tutorial says to put android:theme="@style/Theme.Sherlock" but i don't have this choice, why? i correctly added sherlock library to my project.

推荐答案

http://actionbarsherlock.com/usage。 HTML

按照<一href=\"http://stackoverflow.com/questions/9757400/setting-actionbarsherlock-theme-for-android-app\">link

:删除您创建的JAR。添加ActionBarSherlock到您的应用程序作为一个Android库项目。虽然 ActionBarSherlock文档(见包括在项目)仅引用的Eclipse和Maven对如何做到这一点

: Delete the JAR that you created. Add ActionBarSherlock to your app as an Android library project. While the ActionBarSherlock documentation (see "Including In Your Project") only cites Eclipse and Maven for how to do this,

根据链接

在做Java的code

do in java code

@Override
public void onCreate(Bundle savedInstanceState) {
   if (Build.VERSION.SDK_INT < android.os.Build.VERSION_CODES.ICE_CREAM_SANDWICH){
        this.setTheme(com.actionbarsherlock.R.style.Theme_Sherlock);
   }
   super.onCreate(savedInstanceState);
   ... // MORE CODE ....
}

这篇关于福尔摩斯动作条风格缺失的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆