diff --git a/src/common/wincmn.cpp b/src/common/wincmn.cpp index a9f702acfd..9cad968ed4 100644 --- a/src/common/wincmn.cpp +++ b/src/common/wincmn.cpp @@ -354,7 +354,9 @@ void wxWindowBase::Centre(int direction) yNew += posParent.y; } - Move(xNew, yNew); + // move the centre of this window to this position (not the upper left + // corner as it was done before) + Move(xNew - width / 2, yNew - height / 2); } // fits the window around the children