Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7463)

Unified Diff: WebKit/chromium/src/WebScrollbarImpl.cpp

Issue 3364013: Merge 67001 - 2010-09-08 Peter Kasting <pkasting@google.com>... (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/517/
Patch Set: Created 10 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « WebKit/chromium/src/WebScrollbarImpl.h ('k') | WebKit/chromium/src/win/WebInputEventFactory.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: WebKit/chromium/src/WebScrollbarImpl.cpp
===================================================================
--- WebKit/chromium/src/WebScrollbarImpl.cpp (revision 67003)
+++ WebKit/chromium/src/WebScrollbarImpl.cpp (working copy)
@@ -94,7 +94,7 @@
void WebScrollbarImpl::setValue(int position)
{
- m_scrollbar->setValue(position);
+ m_scrollbar->setValue(position, Scrollbar::NotFromScrollAnimator);
}
void WebScrollbarImpl::setDocumentSize(int size)
@@ -218,7 +218,7 @@
if (negative)
delta *= -1;
}
- m_scrollbar->setValue(m_scrollbar->value() - delta);
+ m_scrollbar->scroll((m_scrollbar->orientation() == HorizontalScrollbar) ? WebCore::ScrollLeft : WebCore::ScrollUp, WebCore::ScrollByPixel, delta);
return true;
}
@@ -262,6 +262,16 @@
return false;
}
+int WebScrollbarImpl::scrollSize(WebCore::ScrollbarOrientation orientation) const
+{
+ return (orientation == m_scrollbar->orientation()) ? (m_scrollbar->totalSize() - m_scrollbar->visibleSize()) : 0;
+}
+
+void WebScrollbarImpl::setScrollOffsetFromAnimation(const WebCore::IntPoint& offset)
+{
+ m_scrollbar->setValue((m_scrollbar->orientation() == HorizontalScrollbar) ? offset.x() : offset.y(), Scrollbar::FromScrollAnimator);
+}
+
void WebScrollbarImpl::valueChanged(WebCore::Scrollbar*)
{
m_client->valueChanged(this);
« no previous file with comments | « WebKit/chromium/src/WebScrollbarImpl.h ('k') | WebKit/chromium/src/win/WebInputEventFactory.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698