Avoid scrolling parts of the screen that don't belong to us

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@51579 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2008-02-07 14:15:45 +00:00
parent 78b65191d6
commit d646b8d6c7

View File

@@ -382,6 +382,12 @@ bool wxVScrolledWindow::ScrollToLine(size_t line)
}
else // overlap between the lines we showed before and should show now
{
// Avoid scrolling visible parts of the screen on Mac
#ifdef __WXMAC__
if (!IsShownOnScreen())
Refresh();
else
#endif
ScrollWindow(0, GetLinesHeight(GetVisibleBegin(), lineFirstOld));
}