Fix content overflow below navigation bar, and black bar above the keyboard when it is shown#156
Open
ebhsgit wants to merge 1 commit intoionic-team:masterfrom
Open
Conversation
…yboard when it is shown. * Both of these issues is due to incorrect calculation of the frameLayoutParams.height value
This was referenced Dec 14, 2020
|
I have tried this fix on a Miui 11 running android 11. It works fine if either the navigation bar or blackbar are being used. If the blackbar is suppressed, i.e. hidden, then the bottom position is missing still. |
itbeyond
added a commit
to itbeyond/cordova-plugin-ionic-keyboard
that referenced
this pull request
Sep 21, 2021
…reen) If you set the preference for resizeOnFullScreen and you do not have your app running in either fullscreen mode (via StatusBar) or Immersive fullscreen mode (via cordova-plugin-fullscreen) the height is calculated wrong and some content between 8 and 40 pixels dependant on device will be off the bottom of the screen. This update looks for isFullScreen Based on and fixes ionic-team#156, ionic-team#117, ionic-team#132, ionic-team#134
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.
Fix for
#117
#132
Both of these issues are due to incorrect calculation of the frameLayoutParams.height value
Child content
getWindowVisibleDisplayFrame()calculates the area which the user can view the content.The top position is below the status bar. The bottom position is above the navigation bar, keyboard and other UI element from the bottom.
If app is in full screen mode, then the actual usable height is the distance from the top of the screen to the bottom of the returned Rect.
So, if app is in full screen, return the bottom position of the rect. Otherwise use the height of the visible area.