My app receives UIKeyboardDidShowNotification and related notifications when it's the focused app. But if another app is focused in the split multitasking view, it no longer receives it. I was testing this in simulator since my physical device don't support split view.
Is this a known simulator bug? Am I missing some configuration options? Does it work as expected on iPad Air 2?
The expected functionality is actually that your app, even when it is not focused, will receive keyboard notifications.
It is mentioned in Getting Started with Multitasking on iPad in iOS 9 WWDC Video at 29:45.
Related
I have one UITextView in my iOS project, when user taps in the text view, if using soft keyboard, the notification keyboardWillShow will be called. My question is if user uses an external hardware keyboard such as bluetooth keyboard, is there any way to know when it is active?
Few Functionalities like
Camera
Push Notifications
bluetooth Keyboard
For these, you need to use Real device instead of simulator. I haven't tested bluetooth keyboard functionality in realtime. but i'm pretending it was one of the feature that to be tested on real device.Please Make me correct if i was thinking wrong.
I have verified that if I use simulator the sofewareWillShow will not trigger, but if I use iPad device and connect to bluetooth keyboard it will be called. The iOS version is 12
We have a WebRTC Swift 4.2 application using Google's native WebRTC code. We are having issues with Apple's App Slide Over Multitasking feature on iPads.
Issue:
What we are seeing is when our Application is running in a video call on an iPad as soon as another app is 'Slide Over' our app, our application stops using the video camera and microphone until the Slide Over app is closed. Once closed our application gets the microphone and camera back.
Expected Result:
Our application is still able to use the camera and microphone and the user is able to use both apps at the same time.
Questions:
Is there a setting we need to turn on to disallow Slide Over apps? If not is there a event we can subscribe to when the slide over happens so we can request camera and microphone access again?
What we have done:
We have set our application to require full screen in the project settings.
We have tried subscribing to the following events on the AppDelegate:
applicationDidEnterBackground, applicationWillResignActive, applicationDidBecomeActive. These events do fire once for the initial Slide over app open and close but not after consecutive Slide Overs with same app.
Turning on all Background mode capabilities. Has no effect.
On our ViewController.swift we have tried to subscribe to viewWillLayoutSubviews event. This event does not fire for apps opened with Slide Over.
Versions:
iOS 11.4.1
Swift 4.2
Xcode 10.1
I filed a bug report with Apple and they said,
"This sounds like expected behavior, given that only one foreground app is allowed at a time."
I have an app, configured for push notifications.
I have a notification service extension and 2 notification content extensions. Notification gets received by the service and it figures out which category to show it. I have custom view controllers for both content extensions, hiding the system default. And 4 actions for each category.
These notifications work and display properly on iPhones running iOS 10-11 and iPads running iOS 11. However, when received on an iPad (4th gen) running 10.3.3 - the notification goes through the service extension, determines the correct category, and then is displayed with a system UI, not my custom controller, and only 2 out of the 4 actions for that notification category are provided. The actions are also presented in-line in the system notification UI, instead of cascading vertically below the notification like it would normally.
I am at a loss, and reaching for the stars here hoping someone has had a similar issue.
iPad running iOS 10.3.3
iPad running iOS 11
I'm having weird experience.
Why push notification is shown (in native banner) when app is foreground?
It's only reproduced on iPhone 7 (iOS10.1.1).
I tested on the other iPhones like a iPhone 5 and iPhone 6s with same app, same iOS version.
It's not shown when app is in foreground as normal.
Push banner appears only on iPhone 7.
Is this normal?
My app is created by Xamarin.forms. (For now, Xamarin convert c# code to objective C, so it's basically objective c)
Thanks.
Starting with iOS 10 developers can control how notifications are shown when the app is in focus. This is done by setting up a UNUserNotificationCenterDelegate.
The userNotificationCenter:willPresentNotification:withCompletionHandler: will be fired on this delegate where UNNotificationPresentationOptions can be passed to the completionHandler to determine if the notification should be displayed along with its sound and badge value update.
Based on your question it sounds like you are using a SDK or framework to add notifications. You can still use a UNUserNotificationCenterDelegate along with most notification SDKs.
Note that on iOS 9 and older devices this delegate isn't available and notifications will not show in the notification center when they are received while your app is in focus. Instead you must must still use UIApplicationDelegate for older versions of iOS and show an in app message for them.
If an application is upgraded to iOS10, and developers of their app have used the UserNotifications framework.Then there are functions by which notification can be displayed as a native banner when app is in foreground.
The UNNotificationPresentationOptions flags allow you to specify UNNotificationPresentationOptionAlert to display an alert using the text provided by the notification.
It effect will same if you are using iOS10 , and app is compatible with UserNotifications framework.
As you mentioned, you have tested the app with Other device with same version, Then might be their app's latest version is not installed on those devices.
It is not based on iPhone7 only. That will work when iOS10 is
installed in your device and application is using UserNotifications
framework for handling the notification.
Is there any way to bring iPhone application into the foreground by pressing a button in the Apple watch
any way other than handoffs!
No, it is not currently possible. WatchConnectivity just serves to exchange data between the two devices, not for changing their statuses.
Of course you may activate a local notification from the watch on the iPhone upon clicking which the coupled application goes to the foreground, but it shall still require an action by the user on the iPhone.