Fix background painting of multi-row toolbars in wxMSW.

The item rectangle used wrong vertical coordinates which didn't matter (much?)
for the single row toolbars but was completely wrong for toolbars with more
than one row.

Don't always anchor the rectangle at the window top to avoid this.

See #13579.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76108 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2014-03-09 20:58:20 +00:00
parent 8f4bd3dfd6
commit f8a7323cbb

View File

@@ -1932,8 +1932,7 @@ bool wxToolBar::HandlePaint(WXWPARAM wParam, WXLPARAM lParam)
}
else
{
rcItem.top = 0;
rcItem.bottom = rectTotal.height;
rcItem.bottom = rcItem.top + rectTotal.height / m_maxRows;
}
// Apparently, regions of height < 3 are not taken into account