iPhone识别home键pressed [英] iPhone identify home button pressed

查看:165
本文介绍了iPhone识别home键pressed的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我如何确定如果应用程序在后台被点击的时候,家里按钮,而不是由外部事件(短信,通话,视频通话)?

How do I identify if the app was in the background when the home button was clicked and not by external events (sms, call, video call)?

推荐答案

如果该应用程序发送到后台,

If the application is sent to background,

applicationDidEnterBackground 

将会得到调用。

如果它是由短信,通话,视频通话,那么,

If it is by sms, call , video call, then,

applicationWillResignActive

将会得到先调用。 ü可以用标识。

will be getting called first. U can identify with that.

这篇关于iPhone识别home键pressed的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆