From 8d1aae54432887d363133d109b835a07a6df4cdb Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 4 Nov 2019 19:32:10 +0100 Subject: [PATCH] Improve compatibility after wxTopLevelWindow::Layout() change The changes of 3241e7a850aa9e55a630e5f790d6a71fe0a83a59 resulted in Layout() not called any longer from wxEVT_SIZE handler for windows that didn't use neither sizers nor constraints themselves, but did call SetAutoLayout(true). Fix this regression by checking for GetAutoLayout() explicitly. See #18472. --- src/common/toplvcmn.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/common/toplvcmn.cpp b/src/common/toplvcmn.cpp index 50a654c4f8..9334bb18fb 100644 --- a/src/common/toplvcmn.cpp +++ b/src/common/toplvcmn.cpp @@ -422,7 +422,8 @@ bool wxTopLevelWindowBase::Layout() // if we're using sizers or constraints - do use them - if ( GetSizer() + if ( GetAutoLayout() + || GetSizer() #if wxUSE_CONSTRAINTS || GetConstraints() #endif