Joe-song-77 commented on issue #603:
URL: 
https://github.com/apache/cordova-plugin-inappbrowser/issues/603#issuecomment-667001853


   I also face the same issue with iOS Cordova 6.1.0 and InAppBrowser 4.0.0. 
Yet, our project works fine with iOS Cordova 5.1.1 and InAppBrowser 3.2.0. Not 
sure what's the root cause. But, I just make a workaround for this issue.
   Declare the below method in CDVWKInAppBrowser:
   
   **- (void)onAppWillEnterForeground {
       if (self.inAppBrowserViewController != nil) {
           NSLog(@"CDVWKInAppBrowser onAppWillEnterForeground to make 
InAppBrowser as key and visible");
           dispatch_async(dispatch_get_main_queue(), ^{
               **[self->tmpWindow makeKeyAndVisible];**
           });
       }
   }**
   
   And, register the observer for event 
'UIApplicationWillEnterForegroundNotification' in 'pluginInitialize' method of 
CDVWKInAppBrowser: 
   **[[NSNotificationCenter defaultCenter] addObserver:self 
selector:@selector(onAppWillEnterForeground)
       name:UIApplicationWillEnterForegroundNotification object:nil];**


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to