找不到以下类: –android.support.wearable.view.WatchViewStub

找不到以下类: –android.support.wearable.view.WatchViewStub,第1张

概述尝试使用Android Wear时,我在Android Studio上的项目中出现此错误: The following classes could not be found: - android.support.wearable.view.WatchViewStub (Fix Build Path, Create Class) 这会导致这些错误

尝试使用Android Wear时,我在AndroID Studio上的项目中出现此错误:

The following classes Could not be found:

– androID.support.wearable.vIEw.WatchVIEwStub (Fix Build Path,Create Class)

这会导致这些错误:

Error:(2) No resource IDentifIEr found for attribute ‘rectLayout’ in
package…

Error:(2) No resource IDentifIEr found for attribute
’roundLayout’ in package…

我怎么能解决这个问题?谢谢!最佳答案当您使用AndroID Studio Project Wizard创建可穿戴应用程序时,会自动包含一个非官方UI库.您还可以使用以下依赖项声明将库添加到build.gradle文件中:

dependencIEs {    compile filetree(dir: 'libs',include: ['*.jar'])    compile 'com.Google.androID.support:wearable:+'    compile 'com.Google.androID.gms:play-services-wearable:+'}

我在build文件夹下创建了一个build.gradle文件,添加了这些依赖项行,一切都很顺利.

http://developer.android.com/training/wearables/apps/layouts.html#UiLibrary 总结

以上是内存溢出为你收集整理的找不到以下类: – android.support.wearable.view.WatchViewStub全部内容,希望文章能够帮你解决找不到以下类: – android.support.wearable.view.WatchViewStub所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/web/1140501.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-31
下一篇 2022-05-31

发表评论

登录后才能评论

评论列表(0条)

保存