无法解析符号ThemeThemeOverlay [英] Cannot resolve symbol Theme, ThemeOverlay
本文介绍了无法解析符号ThemeThemeOverlay的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我将android studio更新到了最新版本-3.0.1.从那时起,它在以下代码行中为Theme和ThemeOverlay抱怨无法解析符号". App运行正常,但文件中的标记为红色.
I updated my android studio to latest version - 3.0.1. Since then it complains 'Cannot resolve symbol' for Theme and ThemeOverlay in the following lines of code. App runs fine but they are marked in RED in the file.
styles.xml
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"></style>
<style name="AppTheme.AppBarOverlay" parent="ThemeOverlay.AppCompat.Dark.ActionBar" />
<style name="AppTheme.PopupOverlay" parent="ThemeOverlay.AppCompat.Light" />
build.gradle已更新为最新版本
build.gradle is updated with the latest version
dependencies {
classpath 'com.android.tools.build:gradle:3.0.1'
}
推荐答案
1)从文件"菜单中关闭项目.
1)Close the project from the File menu.
2)与现有的Android Studio项目一样再次打开该项目.
2)Open the project again as existing Android Studio project.
这解决了我的问题.
这篇关于无法解析符号ThemeThemeOverlay的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文