iMessageApp - MessagesViewController is not in the view hierarchy - swift

I work on the iMessage App and stumbled upon this nasty bug. I would really appreciate the power of the community. Did anyone manage to solve it?
A clear description of the problem:
I work on a Standalone iMessage App. When the iMessage app is active but hidden below the keyboard tapping on the message from that extension opens an app with an empty screen. Investigation of this problem led me to the conclusion that there is no UIWindow attached to the window property of the view in the MessagesViewController. Also, the MessagesViewController is not displayed in the view hierarchy, and MessagesViewController life cycle methods like viewDidLoad and viewDidAppear are not called.
A step-by-step set of instructions to reproduce the problem:
Open an iMessage App (for example Youtube) and send a message from that app to a chat.
Open the iMessage App again
Scroll up so that the iMessage App gets hidden below the keyboard
Scroll down to find a message that you’ve sent in step 1
Tap on the message
The app will expand with an empty view
Here is the bug reproduced in Apple's iMessage Example App https://youtube.com/shorts/3UGyZimctSg?feature=share

Related

UIDocumentBrowserViewController handling back navigation

Apple states that the UIDocumentBrowserViewController should be the rootviewcontroller of your app.
https://developer.apple.com/documentation/uikit/view_controllers/adding_a_document_browser_to_your_app
I have done it this way but I have some UX problem that I cant tackle.
I cant find a good UX solution for navigating back into my App (switching back the app windows rootviewcontroller again to whatever I want).
However I have found that there are some properties where I can manipulate the appearance of the control, "Use the additionalLeadingNavigationBarButtonItems and additionalTrailingNavigationBarButtonItems methods to add buttons to the navigation bar.", but these wont add items to the "main" menu (where I can select other FileProviders, drive dropbox etc.) and where the possibility of going back would be the most clear.
Does anyone implemented, knows a good solution for adding a back button, FAB, back swipe gesture, or something for UIDocumentBrowserViewcontroller which is presented in a as the apps rootviewcontroller?
Im looking for a solution when the user ended the browsing of documents in the UIDocumentBrowserViewcontroller(copy,import etc) and wants to go back to another Viewcontroller.

How can I open pop up ViewController in background mode - iOS

the app in background mode. when detect Ibeacon(https://developer.apple.com/ibeacon/) in background mode open popup.
I can display local-notification to the user when detect Ibeacon detect.
Is Apple allows to open popup in background-mode Swift?
lang - Swift
It is not possible as you need a ViewController or a NavigationController to show the AlertController from.
Also, it is not possible to show a ViewController from a background mode.
By now, your only option is to show LocalNotification or PushNotification and trigger the APP when the users clicks on it.
Check also this other ANSWER

xcode iphone app problem with app not closing on ad click

I have a webview inside mainwindow.xib. Te webview shows an admob ad and when clicked it is supposed to close the app and open the app store. For some reason this is not happening. When the ad is clicked nothing happens. Can this be due to the webview being inside main instead of a viewcontroller? If not then what can be causing this?
It's possible that some other view is intercepting the touches, the UIWebView has user interaction disabled, or the view the UIWebView is a child of has user interaction disabled.
It's hard to say exactly without some more information. Can you take a screenshot of how the mainwindow.xib is laid out?

Regarding Alert View

I am developing one iphone app, when i am clicking on a button i want to show one view which will take the user value for this i am using alert view instead of simple UIView so is it ok to use it b'cos,
I heard if i am using alert view then app will rejected on itunes is this true or we can use alert view.
Thanks & Regards,
Priyanka.
Hi Priyanka as per your problem it seems when the alert view is popped up you want to get some data from user right, so you can do that by taking textfield into uialert view and apple does allow what i said .
Hope this helps.

iPhone - temporarily disable keyboard

G'day All
My app has a first run component that presents a login/signup screen & on successful login/signup moves on to loading the app's data. For those who've seen it the process follows similar style to that in Instagram. If the keyboard is dismissed on entering the password & there's an error it pops back up as soon as it's gone which strikes me as not being a great look. So is there any way to disable the keyboard or prevent user interaction without actually dismissing it while the app sends the user credentials & waits for a response?
Cheers & TIA, Pedro :)
After the first dismiss, I would set the UITextField as disabled. No user Interaction is possible anymore and the keyboard shouldn't pop up anymore. This will also have the nice UI touch of being greyed out.
Additionally, you should have a TextFieldDelegate 1 implement textFieldShouldBeginEditing: and return NO;. That will cause the keyboard to not appear.