summaryrefslogtreecommitdiffstats
path: root/WebCore/platform/wx/ScrollViewWx.cpp
diff options
context:
space:
mode:
authorThe Android Open Source Project <initial-contribution@android.com>2008-10-21 07:00:00 -0700
committerThe Android Open Source Project <initial-contribution@android.com>2008-10-21 07:00:00 -0700
commit9364f22aed35e1a1e9d07c121510f80be3ab0502 (patch)
treed49911209b132da58d838efa852daf28d516df21 /WebCore/platform/wx/ScrollViewWx.cpp
parent87eb0cb35bad8784770ebc807e6c982432e47107 (diff)
downloadexternal_webkit-9364f22aed35e1a1e9d07c121510f80be3ab0502.zip
external_webkit-9364f22aed35e1a1e9d07c121510f80be3ab0502.tar.gz
external_webkit-9364f22aed35e1a1e9d07c121510f80be3ab0502.tar.bz2
Initial Contribution
Diffstat (limited to 'WebCore/platform/wx/ScrollViewWx.cpp')
-rw-r--r--WebCore/platform/wx/ScrollViewWx.cpp17
1 files changed, 3 insertions, 14 deletions
diff --git a/WebCore/platform/wx/ScrollViewWx.cpp b/WebCore/platform/wx/ScrollViewWx.cpp
index 8726fc3..b6c5ae4 100644
--- a/WebCore/platform/wx/ScrollViewWx.cpp
+++ b/WebCore/platform/wx/ScrollViewWx.cpp
@@ -68,6 +68,7 @@ public:
win->Connect(wxEVT_SCROLLWIN_PAGEDOWN, wxScrollWinEventHandler(ScrollViewPrivate::OnScrollWinEvents), NULL, this);
win->Connect(wxEVT_SCROLLWIN_THUMBTRACK, wxScrollWinEventHandler(ScrollViewPrivate::OnScrollWinEvents), NULL, this);
win->Connect(wxEVT_SCROLLWIN_THUMBRELEASE, wxScrollWinEventHandler(ScrollViewPrivate::OnScrollWinEvents), NULL, this);
+ win->Connect(wxEVT_SCROLLWIN_TOP, wxScrollWinEventHandler(ScrollViewPrivate::OnScrollWinEvents), NULL, this);
}
void OnScrollWinEvents(wxScrollWinEvent& e)
@@ -83,30 +84,18 @@ public:
else
pos.y = e.GetPosition();
}
- else if (scrollType == wxEVT_SCROLLWIN_LINEDOWN) {
+ else if ( scrollType == wxEVT_SCROLLWIN_LINEDOWN ) {
if (horiz)
pos.x += LINE_STEP;
else
pos.y += LINE_STEP;
}
- else if (scrollType == wxEVT_SCROLLWIN_LINEUP) {
+ else if ( scrollType == wxEVT_SCROLLWIN_LINEUP ) {
if (horiz)
pos.x -= LINE_STEP;
else
pos.y -= LINE_STEP;
}
- else if (scrollType == wxEVT_SCROLLWIN_PAGEUP) {
- if (horiz)
- pos.x -= m_scrollView->visibleWidth() - PAGE_KEEP;
- else
- pos.y -= m_scrollView->visibleHeight() - PAGE_KEEP;
- }
- else if (scrollType == wxEVT_SCROLLWIN_PAGEDOWN) {
- if (horiz)
- pos.x += m_scrollView->visibleWidth() - PAGE_KEEP;
- else
- pos.y += m_scrollView->visibleHeight() - PAGE_KEEP;
- }
else
return e.Skip();