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

Unified Diff: third_party/WebKit/Source/core/html/forms/TextFieldInputType.cpp

Issue 2383113003: Refactor ScrollableArea::setScrollPosition. (Closed)
Patch Set: nits and rebase 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/core/html/forms/TextFieldInputType.cpp
diff --git a/third_party/WebKit/Source/core/html/forms/TextFieldInputType.cpp b/third_party/WebKit/Source/core/html/forms/TextFieldInputType.cpp
index 04e7e95366f6a0136ed2297eed95163c70bb80cb..2ffecaa4015912209e1f077b875ccc746d2702e5 100644
--- a/third_party/WebKit/Source/core/html/forms/TextFieldInputType.cpp
+++ b/third_party/WebKit/Source/core/html/forms/TextFieldInputType.cpp
@@ -228,13 +228,9 @@ void TextFieldInputType::forwardEvent(Event* event) {
if (PaintLayer* innerLayer = innerEditorLayoutObject->layer()) {
if (PaintLayerScrollableArea* innerScrollableArea =
innerLayer->getScrollableArea()) {
- IntSize scrollOffset(
- !layoutTextControl->style()->isLeftToRightDirection()
- ? innerScrollableArea->scrollWidth().toInt()
- : 0,
- 0);
- innerScrollableArea->scrollToOffset(scrollOffset,
- ScrollOffsetClamped);
+ innerScrollableArea->setScrollPosition(
+ DoublePoint(innerScrollableArea->scrollOrigin()),
+ ProgrammaticScroll, ScrollBehaviorInstant);
}
}
}
« no previous file with comments | « third_party/WebKit/Source/core/frame/FrameView.cpp ('k') | third_party/WebKit/Source/core/layout/LayoutBox.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698