[英]How to check if user is on same view after resumes the activity from background to foreground in android
How to check if user is on same view after resumes the activity in android. 恢复android中的活动后如何检查用户是否在同一视图上。
Regards, AA. 关于AA。
If my understanding is correct about your question, 如果我对您的问题的理解正确,
The onResume
override method will be called. 将调用onResume
覆盖方法。
protected void onResume()
{
super.onResume();
Log.d("MY_CLASS","User is here");
// User is still here.
}
if you want to check if the view is visible or not, You can do the following. 如果要检查视图是否可见,可以执行以下操作。
if(view.isVisible()
{
// Your code here.
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.