From 4a02b73a6afe6b9903d4de59bc658e04ca857423 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sat, 23 Feb 2019 19:03:51 +0100 Subject: [PATCH] Use a symbolic constant instead of hardcoded 3 No real changes, just give a name to the constant used for the number of pixels to leave between an embedded control and its label. --- src/msw/toolbar.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/msw/toolbar.cpp b/src/msw/toolbar.cpp index 8e8a2ea4b9..dbe67831e9 100644 --- a/src/msw/toolbar.cpp +++ b/src/msw/toolbar.cpp @@ -94,6 +94,9 @@ #define TB_GETMAXSIZE (WM_USER + 83) #endif +// Margin between the control and its label. +static const int MARGIN_CONTROL_LABEL = 3; + // ---------------------------------------------------------------------------- // wxWin macros // ---------------------------------------------------------------------------- @@ -1227,7 +1230,7 @@ bool wxToolBar::Realize() if ( staticText && staticText->IsShown() ) { staticTextSize = staticText->GetSize(); - staticTextSize.y += 3; // margin between control and its label + staticTextSize.y += MARGIN_CONTROL_LABEL; } // position the control itself correctly vertically centering it on the