简体   繁体   English

无法解决符号'窗口'错误

[英]Cannot resolve symbol 'window' error

When I add "this.requestWindowFeature(Window.FEATURE_NO_TITLE);" 当我添加"this.requestWindowFeature(Window.FEATURE_NO_TITLE);" to my activity, IDE redden 'Window' word and on tooltip it warns me by "cannot resolve symbol 'window'" 在我的活动中,IDE重写了“Window”字样,并在工具提示上通过“无法解析符号”窗口警告我

protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    this.requestWindowFeature(Window.FEATURE_NO_TITLE);
    setContentView(R.layout.activity_splash_screen);

Any help would be appreciated. 任何帮助,将不胜感激。

Add import android.view.Window; 添加import android.view.Window; to resolve this issue. 解决此问题。

Press and hold ctrl key ( command on MAC ) and click on 'window' text . 按住ctrl键(MAC上'window' command )并单击'window'文本。 A orange bulb will show up on the left panel , click on it , it will ask you to import necessary module . orange bulb将显示在左侧面板上,单击它,它将要求您import必要的模块。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM