我正在尝试在Android Studio for Android Wear中构建一个空的默认项目。我收到此错误:
Error:(23, 41) error: cannot find symbol variable ic_launcher
Error:Execution failed for task ':wear:compileDebugJava'.
> Compilation failed; see the compiler error output for details.
我是可穿戴应用程序开发的新手。任何指针都会有所帮助。
P.S。:我在代码中没有做过任何改变。
您的drawable文件夹为空。在其中放置一个名为“ic_launcher”的图标
您需要将“ic_launcher”图标从mipmap-hdpi文件夹复制到drawable文件夹。我有同样的问题,它有所帮助!
或者,只需通过调用R.mipmap.ic_launcher
来引用mipmap资源