From 80ceb511710a21cf87570a512eed5c33cc5c6e82 Mon Sep 17 00:00:00 2001 From: Romain Goyet Date: Wed, 15 Jun 2016 13:31:49 +0200 Subject: [PATCH] Escher: Proper ScrollView offset Change-Id: I163a5ad4290d662b8d49e034710a8418abc6de4f --- escher/src/scroll_view.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/escher/src/scroll_view.cpp b/escher/src/scroll_view.cpp index b153fa4c7..856041c6b 100644 --- a/escher/src/scroll_view.cpp +++ b/escher/src/scroll_view.cpp @@ -52,7 +52,8 @@ void ScrollView::layoutSubviews() { // Layout contentView KDRect contentFrame; - contentFrame.origin = m_offset; + contentFrame.x = -m_offset.x; + contentFrame.y = -m_offset.y; // We want contentFrame.rightX = verticalIndicatorFrame.x; // contentFrame.x + contentFrame.width = verticalIndicatorFrame.x; contentFrame.width = verticalIndicatorFrame.x - contentFrame.x;