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

Unified Diff: Source/core/page/EventHandler.cpp

Issue 309553007: Adding support for Text Selection on Disabled and Readonly input elements in Android (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixed Linux and Windows Layout test breaks. Created 6 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
« no previous file with comments | « LayoutTests/editing/selection/readonly-disabled-text-selection-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/page/EventHandler.cpp
diff --git a/Source/core/page/EventHandler.cpp b/Source/core/page/EventHandler.cpp
index 22c1e6862a0a40e813a32c5323dbd4adea78492d..82339d8c089f981421ae7fc3df3e9829086b8f68 100644
--- a/Source/core/page/EventHandler.cpp
+++ b/Source/core/page/EventHandler.cpp
@@ -2323,7 +2323,11 @@ bool EventHandler::handleGestureLongPress(const GestureEventWithHitTestResults&
IntPoint hitTestPoint = m_frame->view()->windowToContents(gestureEvent.position());
HitTestResult result = hitTestResultAtPoint(hitTestPoint);
Node* innerNode = result.innerNode();
- if (!result.isLiveLink() && innerNode && (innerNode->isContentEditable() || innerNode->isTextNode())) {
+ if (!result.isLiveLink() && innerNode && (innerNode->isContentEditable() || innerNode->isTextNode()
+#if OS(ANDROID)
+ || innerNode->canStartSelection()
+#endif
+ )) {
selectClosestWordFromHitTestResult(result, DontAppendTrailingWhitespace);
if (m_frame->selection().isRange()) {
focusDocumentView();
« no previous file with comments | « LayoutTests/editing/selection/readonly-disabled-text-selection-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698