added ScrollLines/Pages

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@11210 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2001-07-29 22:47:40 +00:00
parent c57e33394c
commit b9b3393e48
3 changed files with 30 additions and 0 deletions

View File

@@ -940,6 +940,24 @@ void wxWindowMSW::ScrollWindow(int dx, int dy, const wxRect *prect)
::ScrollWindow(GetHwnd(), dx, dy, prect ? &rect : NULL, NULL);
}
static void ScrollVertically(int kind, int count)
{
}
void wxWindowMSW::ScrollLines(int lines)
{
bool down = lines > 0;
ScrollVertically(down ? SB_LINEDOWN : SB_LINEUP, down ? lines : -lines);
}
void wxWindowMSW::ScrollPages(int pages)
{
bool down = pages > 0;
ScrollVertically(down ? SB_PAGEDOWN : SB_PAGEUP, down ? pages : -pages);
}
// ---------------------------------------------------------------------------
// subclassing
// ---------------------------------------------------------------------------