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

Unified Diff: third_party/WebKit/WebCore/rendering/TextControlInnerElements.cpp

Issue 39071: Fix http://crbug.com/8302. positionForCoordinates upstream was replaced with... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 10 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/WebCore/rendering/TextControlInnerElements.cpp
===================================================================
--- third_party/WebKit/WebCore/rendering/TextControlInnerElements.cpp (revision 10784)
+++ third_party/WebKit/WebCore/rendering/TextControlInnerElements.cpp (working copy)
@@ -44,7 +44,7 @@
RenderTextControlInnerBlock(Node* node, bool isMultiLine) : RenderBlock(node), m_multiLine(isMultiLine) { }
virtual bool nodeAtPoint(const HitTestRequest&, HitTestResult&, int x, int y, int tx, int ty, HitTestAction);
- virtual VisiblePosition positionForCoordinates(int x, int y);
+ virtual VisiblePosition positionForPoint(const IntPoint&);
private:
bool m_multiLine;
};
@@ -59,10 +59,10 @@
return RenderBlock::nodeAtPoint(request, result, x, y, tx, ty, placeholderIsVisible ? HitTestBlockBackground : hitTestAction);
}
-VisiblePosition RenderTextControlInnerBlock::positionForCoordinates(int x, int y)
+VisiblePosition RenderTextControlInnerBlock::positionForPoint(const IntPoint& point)
{
- int contentsX = x;
- int contentsY = y;
+ int contentsX = point.x();
+ int contentsY = point.y();
// Multiline text controls have the scroll on shadowAncestorNode, so we need to take that
// into account here.
@@ -72,7 +72,7 @@
renderer->layer()->addScrolledContentOffset(contentsX, contentsY);
}
- return RenderBlock::positionForCoordinates(contentsX, contentsY);
+ return RenderBlock::positionForPoint(IntPoint(contentsX, contentsY));
}
TextControlInnerElement::TextControlInnerElement(Document* doc, Node* shadowParent)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698