On Sat, 2 Oct 2021 23:53:02 GMT, Marius Hanl <mh...@openjdk.org> wrote:

> This PR fixes a visual glitch which may happen when showing a dialog.
> When a max height is set and the pref height of the dialog content is bigger 
> the dialog starts to flicker between the max height and the pref height.
> 
> This happens because in one case the height is not bound between the min and 
> the max height (-> max height is ignored).
> - First layout pass: The dialog will incorrectly resize to a the pref height, 
> which is bigger than the max height
> - Second layout pass: The dialog will correctly resize to the max height
> - repeat
> 
> The fix is to bound the height there as well (Fix in **layoutChildren()**).
> Example where a red stackpane has a bigger pref height then the max height of 
> the dialog (see also example in ticket):
> 
> https://user-images.githubusercontent.com/66004280/135734463-03b422f4-710d-4436-9715-c91bdb768d76.mp4
> 
> * only the max height test fails before and succeeds after.

Marked as reviewed by aghaisas (Reviewer).

In this case limiting the height between min and max makes sense.

-------------

PR: https://git.openjdk.java.net/jfx/pull/637

Reply via email to