iOS 开发实用技术导航
NSHipster 中文版
› http://nshipster.cn/
cocos2d 开源 2D 游戏引擎
› http://www.cocos2d-iphone.org/
CocoaPods
› http://cocoapods.org/
Google Analytics for Mobile 统计解决方案
› http://code.google.com/mobile/analytics/
WWDC
› https://developer.apple.com/wwdc/
Design Guides and Resources
› https://developer.apple.com/design/
Transcripts of WWDC sessions
› http://asciiwwdc.com
Cocoa with Love
› http://cocoawithlove.com/
Cocoa Dev Central
› http://cocoadevcentral.com/
NSHipster
› http://nshipster.com/
Style Guides
› Google Objective-C Style Guide
› NYTimes Objective-C Style Guide
Useful Tools and Services
› Charles Web Debugging Proxy
› Smore
babyname
V2EX  ›  iDev

从后台进入前台, ViewController 没有一个方法会调用,如何通知 ViewController 更新数据呢?

  •  
  •   babyname · Mar 22, 2015 · 3598 views
    This topic created in 4245 days ago, the information mentioned may be changed or developed.
    从后台进入前台, ViewController 没有一个方法会调用,只有 applicationWillEnterForeground(application: UIApplication) 会调用,如何通知 ViewController 更新数据呢?
    6 replies  •  2015-03-23 19:27:34 +08:00
    eternityz
    eternityz
    Mar 22, 2015
    1
    NSNotificationCenter
    babyname
    babyname
    OP
    Mar 22, 2015
    3
    @wujichao
    @eternityz 谢谢,不过感觉 UIApplicationWillEnterForegroundNotification 才是我想要的
    UIApplicationDidBecomeActiveNotification 在viewload 时候也会调用,UIApplicationWillEnterForegroundNotification 只有在推出后台后,再进入才会调用。
    984561417
    984561417
    Mar 23, 2015
    4
    NSNotificationCenter
    lyklykkkkkkk
    lyklykkkkkkk
    Mar 23, 2015
    5
    ViewController.... 厉害啊 MVC占了2/3
    ianisme
    ianisme
    Mar 23, 2015 via iPhone
    6
    通知中心
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   4673 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 62ms · UTC 09:23 · PVG 17:23 · LAX 01:23 · JFK 04:23
    ♥ Do have faith in what you're doing.