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

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

Issue 2877623005: Make DragController::DragIsMove return false when selection does not have focus (Closed)
Patch Set: Add layout test Created 3 years, 7 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/page/DragController.cpp
diff --git a/third_party/WebKit/Source/core/page/DragController.cpp b/third_party/WebKit/Source/core/page/DragController.cpp
index 5283c0e7cc1b807a4e5f9a247b4be2b2542417f9..8d4750d96ddbe8998be606acf1f10a699bcead2a 100644
--- a/third_party/WebKit/Source/core/page/DragController.cpp
+++ b/third_party/WebKit/Source/core/page/DragController.cpp
@@ -200,6 +200,7 @@ static DocumentFragment* DocumentFragmentFromDragData(
bool DragController::DragIsMove(FrameSelection& selection,
DragData* drag_data) {
return document_under_mouse_ == drag_initiator_ &&
+ selection.SelectionHasFocus() &&
selection.ComputeVisibleSelectionInDOMTreeDeprecated()
.IsContentEditable() &&
selection.ComputeVisibleSelectionInDOMTreeDeprecated().IsRange() &&

Powered by Google App Engine
This is Rietveld 408576698