maui
maui copied to clipboard
iOS Keyboard Scrolling - Maui Community Toolkit Popup
The MCT popup code was originally here, but moved to here so that the testing of the popup could be implemented without blocking the other parts of the PR.
MCT Popup
The iOS Keyboard Scrolling solution I posted a few months ago had an issue with the Maui Community Toolkit Popup. The main issue was that the popup has some external scrolling going on. The Maui code would grab the initial position of the cursor, the external scrolling would happen, and then our Maui code would scroll from the initial position making things messy and incorrect. The solution I came up with is refactoring the portion of the code that calculates where the cursor on the editor/entry is to later in the code and monitoring the ContainerView to see if there was a change in position and allotting time until this external scrolling is finished to start our scroll calculations. This should also help in future situations where we are not able to control an external scroll.
MCT Popup Example (click me!)
Before | After |
---|---|
Issues Fixed
Fixes https://github.com/PureWeen/ShanedlerSamples/issues/13