iphone - how can i tell when the phone is in a call when i return to my app without checking the status bar frame? -


i using uiapplicationwillchangestatusbarframenotification tell when status bar change, , me figure out when call in progress goes away, , behavior like.

however, there 1 scene in app in take full screen, , includes hiding status bar … except not hide status bar when in call.

my understanding way status-bar first show if (a) phone call, (b) return app.

so … when return app upon receiving phone call … there no green status bar. (fwiw, green status bar appear when tap on app make status bar , nav bar , tab bar re-appear, it's not entirely gone; hidden because told hidden. in simulator, performing "hardware -> toggle in-call status bar" works like, don't think behavior ever occur way in real world.)

i found answer how notified when user opens iphone app while in phone call? … but works if statusbar visible when app re-opened.

i want know how tell i'm in call when return app can manually unhide green status bar while user looking @ scene otherwise hide status bar.

my question thus: there interface tell me information can query when return app in applicationdidbecomeactive: or via other sort of notification?

you can use ctcallcenter find out if there current cell call. , register handler class notified cell state changes.

    ctcallcenter *callcenter = [[ctcallcenter alloc] init];      // if no calls in progress, value of property nil.     if ([callcenter currentcalls] != nil) {         ... call present...     }     [callcenter release]; 

Comments

Popular posts from this blog

c# - SVN Error : "svnadmin: E205000: Too many arguments" -

c# - Copy ObservableCollection to another ObservableCollection -

All overlapping substrings matching a java regex -