中文字幕理论片,69视频免费在线观看,亚洲成人app,国产1级毛片,刘涛最大尺度戏视频,欧美亚洲美女视频,2021韩国美女仙女屋vip视频

打開APP
userphoto
未登錄

開通VIP,暢享免費(fèi)電子書等14項超值服

開通VIP
Error at lib support appcompat_v7

 

I am having trouble to at library appcompat_v7

It have error on path

res/values-v21/styles_base.xml

and at line 75 show error - below 75 to 78:

<style name="Base.Widget.AppCompat.ActionButton"          parent="android:Widget.Material.ActionButton"> </style>

at console:

home/user/workspace/appcompat_v7/res/values-v21/themes_base.xml:156: error: Error: No resource found that matches the given name: attr 'android:colorControlNormal'.

and several error similares changing just the 'android:*'

How can I fix this?

shareimprove this question

    
Have the same problem here. Looks like it's a problem with the API v21 update –  Raul Pinto Oct 19 '14 at 18:47
    
Did you try using the new SDK of API level 21? –  Raul Pinto Oct 19 '14 at 18:51
1  
I finally made my app running by switching to API level 21 for my app as well as the appcompat project/module (i.e. the project that includes the resources used by compatibility lib v21). Now I found out, that v21 doesn't seem to include the holo theme and my app looks totally different :( –  Raul Pinto Oct 19 '14 at 19:31
    
So I recovered appcompat-v7 resources from "Android Support Repository" by extracting from appcompat-v7-20.0.0.aar and getting android-support-v7-appcompat.jar from my git repo. Now it's running again with the style it had before the update. –  Raul Pinto Oct 20 '14 at 11:46
    
@RaulPinto, Yes, I am compiling with the API 21. –  lcsvcn Oct 27 '14 at 13:56

4 Answers

Ok, I'm not sure, if this a real "solution" but here is my theory and what I did:

My Theory

After updating the "Android Support Library" version 21, I got a similar error. It seems, my IntelliJ didn't update the resources in my module correctly, which pointed to the ressources directory for appcompat.

Furthermore, I had some widgets and Code that directly pointed to drawables in those ressources.

But in v21 of the Android Support Library Google dropped support for the Holo theme!

Hence, the compiler complains about not finding the resources my theme depends on.

What I did

When it compiled

To be honest, I'm not really sure in how I came out making this work. I guess, I used did some restarting and cache emptying etc. Copying ressources to my project's folder etc. When my app finally started, it looked different! Of course, it had the Material theme instead of the Holo theme.

And not everything survived this transition. E.g. the Action Bar was black (standard) instead of green (my theme). So I tried to go back to an old version of appcompat instead of migrating my whole app to Material.

Since you asked me for my solution, I'm posting what I did to "downgrade" to appcompat v20.

Downgrading to appcompat v20

  1. Start SDK Manager
  2. Download Android Support Repository
  3. Go to directory \android-sdk\extras\android\m2repository\com\android\support\appcompat-v7\20.0.0\ where Android SDK is installed
  4. Extract all files from appcompat-v7-20.0.0.aar (it's a zip file) to libs\appcompat\ directory in my project, after I created the directory appcompat
  5. Added these as a module in my IntelliJ and made my project depend on this module
  6. Recovered android-support-v7-appcompat.jar for v20 from my git repository
  7. Used the recovered appcompat jar instead of the v21 one

Step 6 is the one, I found very difficult. I expected the classes.jar from the .aar file to be the android-support-v7-appcompat.jar, but it wasn't. I even don't know, where you can get the android-support-v7-appcompat.jar from in the right version because I didn't find it in the repository. And I didn't want to download it from "somewhere in the internet".

I was "lucky", it already was in my git in the correct version.

Now my app compiled and looked correctly. Hope so does yours!

shareimprove this answer

1  
I was not so lucky to have it already in my git repo; and the sdk updater deleted it from the file system. What I did in the end: git clone from android.googlesource.com/platform/frameworks/support.git/+/…, git checkout to that tag (cae6ca....) and then have Eclipse import the v7 folder as a project –  jdowdell Oct 30 '14 at 1:09
    
So, for my part, I had to checkout Branch android-support-lib-19.1.0 from the git repository (android.googlesource.com/platform/frameworks/support.git/+/…), because otherwise my app didn't run under Android 2.3.4 (API Level 10). –  Raul Pinto Nov 11 '14 at 14:11
    
You can download v20 support lib here: dl-ssl.google.com/android/repository/support_r20.zip Then follow the steps here: developer.android.com/tools/support-library/setup.html Follow the 'Adding libraries with resources' guide. –  Oliver Evans Nov 26 '14 at 10:28

home/user/workspace/appcompat_v7/res/values-v21/themes_base.xml:156: error: Error: No resource found that matches the given name: attr 'android:colorControlNormal'.

I assumed values-v21 stands for api level 21, so I updated to android 5.0 and it works for me.

shareimprove this answer

    
Agreed. A coworker who had the same problem says it went away when he specified the latest Android and API versions in the project properties. –  mirabilos Feb 17 at 11:15

Had same problem after upgrading my Eclipse and import "Android Support Library" in workspace.

I think it's a bad solution to "Downgrading to appcompat" so I tried to find another way and found it.My problem was that my "Project Build Target" of AppCompat was set to API lvl 19. So this is a problem:

-Eclipse wasn't load the data for API lvl 21 for AppCompat.

-Appcompat have Target API lvl 19, but trying to set style for API lvl 21.

Maybe You have same problem so checkout what was help me:

1.

Right click on Appcompat project => Properties => Android => Checkout where was your mark, and if it's not set on Android 5.0 - fix it and click ok.

2.

Project => Clean => Set "Clean all projects" => Ok

P.S. Sorry if I have mistakes - English isn't my native language.

shareimprove this answer

My solution is more radical:delete all styles files and every reference for them

shareimprove this answer

    
Welcome to SO. With all detailed and relevant answers there, I would suggest you to spend some more time explain why and how this is better approach than others above. Thanks. –  IsabelHM Jan 21 at 22:34

Your Answer

 
本站僅提供存儲服務(wù),所有內(nèi)容均由用戶發(fā)布,如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請點(diǎn)擊舉報。
打開APP,閱讀全文并永久保存 查看更多類似文章
猜你喜歡
類似文章
在Eclipse添加Android兼容包( v4、v7 appcompat )
關(guān)于Eclipse創(chuàng)建Android項目時,會多出一個appcompat
Android關(guān)于Theme.AppCompat相關(guān)問題的深入分析
播放SDK · 金山云
Android下 使用百度地圖sdk
開放平臺
更多類似文章 >>
生活服務(wù)
熱點(diǎn)新聞
分享 收藏 導(dǎo)長圖 關(guān)注 下載文章
綁定賬號成功
后續(xù)可登錄賬號暢享VIP特權(quán)!
如果VIP功能使用有故障,
可點(diǎn)擊這里聯(lián)系客服!

聯(lián)系客服