其他分享
首页 > 其他分享> > android-在各处都导入Holo时出错

android-在各处都导入Holo时出错

作者:互联网

我在几个站点上都遵循了指南,但无法正常工作.我确保他们从现有资源创建了项目,并将其作为库包含在我的项目中,检查了目标,等等.我不确定我缺少什么.

我收到以下错误:

[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values\styles.xml:246: error: Error: No resource found that matches the given name: attr 'windowActionBar'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values\styles.xml:247: error: Error: No resource found that matches the given name: attr 'windowNoTitle'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:12: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:14: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock.Light'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:16: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock.Light.DarkActionBar'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:18: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock.ForceOverflow'.
[2012-08-29 21:04:45 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values-v14\styles.xml:20: error: Error retrieving parent for item: No resource found that matches the given name 'Theme.Sherlock.Light.ForceOverflow'.
[2012-08-29 21:46:56 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values\styles.xml:247: error: Error retrieving parent for item: No resource found that matches the given name '@style/Theme.HoloEverywhereDark.Sherlock'.
[2012-08-29 21:46:56 - IT Guru] C:\Workspace\HoloEverywhereLib\res\values\styles.xml:253: error: Error retrieving parent for item: No resource found that matches the given name '@style/Theme.HoloEverywhereLight.Sherlock'.

遵循的指南:

Error importing HoloEverywhere

https://github.com/ChristopheVersieux/HoloEverywhere

解决方法:

您链接到的《 HoloEverywhere》指南有些过时了,这两个主题现在称为Holo.Theme和Holo.Theme.Light.

因此,请在您的Android清单中更改这些行:

android:theme="@style/Theme.HoloEverywhereDark.Sherlock"

要么

android:theme="@style/Theme.HoloEverywhereLight.Sherlock"

 android:theme="@style/Holo.Theme"

要么

android:theme="@style/Holo.Theme.Light"

然后,Project-> Clean,查看错误是否消失.

标签:android-theme,android
来源: https://codeday.me/bug/20191127/2076344.html