0
我想关闭搜索视图,在主页按钮的操作栏中关闭它。目前我正在使用intent,操作栏主页按钮点击的方法是什么?android动作栏主页按钮方法
这是我的方式来取消搜索或折叠它。有没有更平滑的方法?
case R.id.action_cancel:{
Intent intent = new Intent(this, MainActivity.class);
intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
startActivity(intent);