zellis-haasl opened a new pull request, #1131:
URL: https://github.com/apache/cordova-plugin-inappbrowser/pull/1131

   ## Summary
   
   - Adds a fallback to iterate `UIApplication.connectedScenes` when 
`viewController.view.window.windowScene` returns nil, ensuring the 
InAppBrowser's temporary `UIWindow` is always associated with an active 
`UIWindowScene` on iOS 13+.
   
   ## Problem
   
   On iOS 13+ with cordova-ios 8, the main Cordova window's scene reference 
isn't always available at the time the InAppBrowser creates its temporary 
`UIWindow`. When `windowScene` is nil, the code falls through to the 
frame-based `initWithFrame:` initializer, which produces a window with no scene 
association. On scene-based iOS versions, this window is never displayed -- 
resulting in a white/blank screen.
   
   ## Solution
   
   Before falling back to `initWithFrame:`, the patch searches all connected 
scenes for an active foreground `UIWindowScene`. This ensures 
`initWithWindowScene:` is used whenever a valid scene exists, while preserving 
the frame-based fallback for pre-iOS 13 devices.
   
   ## Test plan
   
   - [ ] Open InAppBrowser on iOS 13+ device/simulator with cordova-ios 8 -- 
verify the browser renders correctly
   - [ ] Verify InAppBrowser still works on older iOS versions (frame-based 
fallback path)
   - [ ] Test with `hidden=yes` option to confirm hidden-then-shown flow is 
unaffected
   
   
   Made with [Cursor](https://cursor.com)


-- 
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.

To unsubscribe, e-mail: [email protected]

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