这是LogCat:
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.---.---/com.---.---.ManageDebts}: java.lang.IllegalStateException: You must use Theme.Sherlock, Theme.Sherlock.Light, Theme.Sherlock.Light.DarkActionBar, or a derivative.
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1815)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1831)
at android.app.ActivityThread.access$500(ActivityThread.java:122)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1024)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:132)
at android.app.ActivityThread.main(ActivityThread.java:4123)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:491)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:841)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:599)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.IllegalStateException: You must use Theme.Sherlock, Theme.Sherlock.Light, Theme.Sherlock.Light.DarkActionBar, or a derivative.
at com.actionbarsherlock.internal.ActionBarSherlockCompat.generateLayout(ActionBarSherlockCompat.java:1003)
at com.actionbarsherlock.internal.ActionBarSherlockCompat.installDecor(ActionBarSherlockCompat.java:915)
at com.actionbarsherlock.internal.ActionBarSherlockCompat.setContentView(ActionBarSherlockCompat.java:849)
at com.actionbarsherlock.app.SherlockListActivity.setContentView(SherlockListActivity.java:229)
at com.kickinglettuce.debtplanner.ManageDebts.onCreate(ManageDebts.java:70)
at android.app.Activity.performCreate(Activity.java:4397)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1048)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1779)
... 11 more
它说我需要使用特定的Sherlock主题,好吧,这就是我正在做的事情:
清单中的:
<application
android:theme="@style/DPFTheme" >
Res文件夹值/样式:
<style name="DPFTheme" parent="@style/Theme.Sherlock.Light" />
Res文件夹值-v11 /样式:
我相信我已经涵盖了所有基地。或者我呢?
<style name="DPFTheme" parent="@android:style/Theme.Holo.Light" />
现在,这个应用程序有几千个用户,我只看到这个错误约5次左右。那么也许它是特定于设备的?我不确定。