-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Window::get_min_size causing AcceptDialog::_get_contents_minimum_size autocorrelation #61982
Fix Window::get_min_size causing AcceptDialog::_get_contents_minimum_size autocorrelation #61982
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems sensible to me, but I wonder if that won't break assumptions and introduce regressions. E.g. would it always resize dialogs when changing the contents (e.g. switching tabs)?
May be as bad as you guessed, but |
I looked further into the source code and I was confused. If But So it messes up between |
The issue is caused by these codes: Lines 233 to 234 in 362f53f
Lines 127 to 140 in 362f53f
Lines 601 to 603 in 362f53f
Line 623 in 362f53f
So Maybe we should use |
2c27828
to
53bd72f
Compare
In the code, I searched for related setters/getters: It seems that there is no case to get the result of So the current change is no problem. |
Thanks! |
Oops I merged thinking that this was still the version I had review before, my bad. I guess we'll see how it goes in the |
It seems fine and fixes the issue. |
Fix #55894.
Previously, the calculation is based on the previous min size, which does not seem appropriate.
Edit:
Previously, the
min_size
inWinodw
may end up being reset automatically in some cases, this may be inappropriate.And the new value of the setting is related to the calculation of
_get_contents_minimum_size
, which in turn depends onmin_size
, that is, the currentmin_size
is relate to the previousmin_size
, same for_get_contents_minimum_size
. Eventually,min_size
/_get_contents_minimum_size
may get bigger and bigger.