2016-07-15 3 views
0

ユーザーが拡張ステータスバーから戻るときにアクションを実行する必要があります。 できること: 1.ユーザーがステータスバーにタッチします。 2.ステータスバーからの復帰:このコードステータスバーを含むタッチ操作を検出する

[[NSNotificationCenter defaultCenter] addObserver:self 
              selector:@selector(onStop) 
               name:UIApplicationWillResignActiveNotification 
               object:nil]; 

を使用すると、どのようにこのアクションを検出するには? この方法は機能しません

[[NSNotificationCenter defaultCenter] addObserver:self 
              selector:@selector(onStart) 
               name:UIApplicationWillEnterForegroundNotification 
               object:nil]; 

すべての解決方法はありますか?

答えて

0

検出された溶液。

代わり

UIApplicationWillEnterForegroundNotificationUIApplicationDidBecomeActiveNotification

使用 。

関連する問題