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

Unified Diff: third_party/WebKit/Source/core/page/FocusController.cpp

Issue 2691243002: Revert of Make FrameSelection to hold non-canonicalized positions (Closed)
Patch Set: Created 3 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 | « third_party/WebKit/Source/core/frame/FrameView.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/page/FocusController.cpp
diff --git a/third_party/WebKit/Source/core/page/FocusController.cpp b/third_party/WebKit/Source/core/page/FocusController.cpp
index 110d8bf12a8de8c3fa4cf6a7c0088d3b2008b582..c75f524ac1ac4de629c2045c739a8667a6e8457c 100644
--- a/third_party/WebKit/Source/core/page/FocusController.cpp
+++ b/third_party/WebKit/Source/core/page/FocusController.cpp
@@ -1076,11 +1076,10 @@
return;
FrameSelection& selection = oldFocusedFrame->selection();
- const SelectionInDOMTree& selectionInDOMTree = selection.selectionInDOMTree();
- if (selectionInDOMTree.isNone())
- return;
-
- Node* selectionStartNode = selectionInDOMTree.base().anchorNode();
+ if (selection.isNone())
+ return;
+
+ Node* selectionStartNode = selection.selection().start().anchorNode();
if (selectionStartNode == newFocusedElement ||
selectionStartNode->isDescendantOf(newFocusedElement))
return;
« no previous file with comments | « third_party/WebKit/Source/core/frame/FrameView.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698