Fix: IAM now showing after switching to 3-button-navigation mode#2284
Merged
jinliu9508 merged 1 commit intomainfrom Apr 25, 2025
Merged
Fix: IAM now showing after switching to 3-button-navigation mode#2284jinliu9508 merged 1 commit intomainfrom
jinliu9508 merged 1 commit intomainfrom
Conversation
nan-li
reviewed
Apr 22, 2025
OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/DeviceUtils.kt
Outdated
Show resolved
Hide resolved
jkasten2
requested changes
Apr 22, 2025
Member
jkasten2
left a comment
There was a problem hiding this comment.
There is a comment "Does not work for cases when keyboard is full screen.", is this still true with the new API used in this PR?
OneSignalSDK/onesignal/core/src/main/java/com/onesignal/common/DeviceUtils.kt
Outdated
Show resolved
Hide resolved
dffb48c to
3c73250
Compare
jkasten2
approved these changes
Apr 25, 2025
Merged
This was referenced May 8, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
One Line Summary
Fix some IAMs being suppressed under some specific view layouts with the 3 button navigation mode
Details
Motivation
Fix the bug that causes IAM not shown when user is on the 3 button navigation mode.
Scope
The PR changes how we determine if keyboard is currently open by using WindowInsets instead of using a fixed value for the offset of current view height and the screen height. This change will only be available for devices running on Android 11 and up.
Testing
Manual testing
I was unable to reproduce the scenario that prevent IAM from showing. Instead, I tested whether isKeyboardUp returns the correct value with the soft keyboard being open and close.
Devices I tested:
Both
Affected code checklist
Checklist
Overview
Testing
Final pass
This change is