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

Unified Diff: third_party/WebKit/Source/platform/graphics/CompositorMutableState.cpp

Issue 2387883002: Use float for scroll offset. (Closed)
Patch Set: Fix README.md Created 4 years, 2 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
Index: third_party/WebKit/Source/platform/graphics/CompositorMutableState.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/CompositorMutableState.cpp b/third_party/WebKit/Source/platform/graphics/CompositorMutableState.cpp
index 6313cbfe2c1f4822de8ce4bb795b76426d3954a5..9ed264d6b2f926a15c0be6aa1ae8b3d191e06bfe 100644
--- a/third_party/WebKit/Source/platform/graphics/CompositorMutableState.cpp
+++ b/third_party/WebKit/Source/platform/graphics/CompositorMutableState.cpp
@@ -45,11 +45,11 @@ void CompositorMutableState::setTransform(const SkMatrix44& matrix) {
m_mutation->setTransform(matrix);
}
-double CompositorMutableState::scrollLeft() const {
+float CompositorMutableState::scrollLeft() const {
return m_scrollLayer ? m_scrollLayer->CurrentScrollOffset().x() : 0.0;
}
-void CompositorMutableState::setScrollLeft(double scrollLeft) {
+void CompositorMutableState::setScrollLeft(float scrollLeft) {
if (!m_scrollLayer)
return;
@@ -64,11 +64,11 @@ void CompositorMutableState::setScrollLeft(double scrollLeft) {
m_mutation->setScrollLeft(scrollLeft);
}
-double CompositorMutableState::scrollTop() const {
+float CompositorMutableState::scrollTop() const {
return m_scrollLayer ? m_scrollLayer->CurrentScrollOffset().y() : 0.0;
}
-void CompositorMutableState::setScrollTop(double scrollTop) {
+void CompositorMutableState::setScrollTop(float scrollTop) {
if (!m_scrollLayer)
return;
gfx::ScrollOffset offset = m_scrollLayer->CurrentScrollOffset();

Powered by Google App Engine
This is Rietveld 408576698