From ecb017924cfd415a288cec52098a3f11a4a9b5de Mon Sep 17 00:00:00 2001 From: Ron Lee Date: Wed, 8 Mar 2000 15:06:28 +0000 Subject: [PATCH] final (touch wood) tidy after things went pearshaped on line 666 git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@6528 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/generic/scrolwin.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/generic/scrolwin.cpp b/src/generic/scrolwin.cpp index 02519f2359..6834384fad 100644 --- a/src/generic/scrolwin.cpp +++ b/src/generic/scrolwin.cpp @@ -633,7 +633,6 @@ void wxScrolledWindow::OnChar(wxKeyEvent& event) szx, szy, // view size (total) clix, cliy; // view size (on screen) - int y; ViewStart(&stx, &sty); GetClientSize(&clix, &cliy); GetVirtualSize(&szx, &szy); @@ -659,12 +658,13 @@ void wxScrolledWindow::OnChar(wxKeyEvent& event) szy = -1; } + int dsty; switch ( event.KeyCode() ) { case WXK_PAGEUP: case WXK_PRIOR: - y = sty - (5 * cliy / 6); - Scroll(-1, (y == -1) ? 0 : y); + dsty = sty - (5 * cliy / 6); + Scroll(-1, (dsty == -1) ? 0 : dsty); break; case WXK_PAGEDOWN: -- 2.45.2