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

Unified Diff: Source/core/layout/LayoutObject.cpp

Issue 1303653002: Introduce LayoutObject::createPositionWithAffinity(int offset) (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 2015-08-19T12:20:28 Created 5 years, 4 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 | « Source/core/layout/LayoutObject.h ('k') | Source/core/layout/LayoutReplaced.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/LayoutObject.cpp
diff --git a/Source/core/layout/LayoutObject.cpp b/Source/core/layout/LayoutObject.cpp
index 0892709745635288d2a7b1efe0030c0615333d8e..e769d3e4ef0e8b17d85b3367c1cfb49d5e84e2b2 100644
--- a/Source/core/layout/LayoutObject.cpp
+++ b/Source/core/layout/LayoutObject.cpp
@@ -2594,7 +2594,7 @@ void LayoutObject::removeShapeImageClient(ShapeValue* shapeValue)
PositionWithAffinity LayoutObject::positionForPoint(const LayoutPoint&)
{
- return createPositionWithAffinity(caretMinOffset(), DOWNSTREAM);
+ return createPositionWithAffinity(caretMinOffset());
}
void LayoutObject::updateDragState(bool dragOn)
@@ -3036,13 +3036,18 @@ PositionWithAffinity LayoutObject::createPositionWithAffinity(int offset, EAffin
return PositionWithAffinity();
}
+PositionWithAffinity LayoutObject::createPositionWithAffinity(int offset)
+{
+ return createPositionWithAffinity(offset, DOWNSTREAM);
+}
+
PositionWithAffinity LayoutObject::createPositionWithAffinity(const Position& position)
{
if (position.isNotNull())
return PositionWithAffinity(position);
ASSERT(!node());
- return createPositionWithAffinity(0, DOWNSTREAM);
+ return createPositionWithAffinity(0);
}
CursorDirective LayoutObject::getCursor(const LayoutPoint&, Cursor&) const
« no previous file with comments | « Source/core/layout/LayoutObject.h ('k') | Source/core/layout/LayoutReplaced.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698