Changeset 152198 in webkit
- Timestamp:
- Jun 28, 2013 5:09:09 PM (11 years ago)
- Location:
- trunk
- Files:
-
- 4 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r152185 r152198 1 2013-06-28 Ryosuke Niwa <rniwa@webkit.org> 2 3 An element with -webkit-user-select: all should be selected on single click 4 https://bugs.webkit.org/show_bug.cgi?id=117864 5 6 Reviewed by Darin Adler. 7 8 Add tests for single clicking on an element with user-select: all. 9 We select the entire element regardless of whether the user had clicked on text or an image 10 to be consistent even though Firefox requires a double click on the latter case. 11 12 * editing/selection/user-select-all-with-image-single-click-expected.txt: Added. 13 * editing/selection/user-select-all-with-image-single-click.html: Added. 14 * editing/selection/user-select-all-with-single-click-expected.txt: Added. 15 * editing/selection/user-select-all-with-single-click.html: Added. 16 1 17 2013-06-28 Ryosuke Niwa <rniwa@webkit.org> 2 18 -
trunk/Source/WebCore/ChangeLog
r152197 r152198 1 2013-06-28 Ryosuke Niwa <rniwa@webkit.org> 2 3 An element with -webkit-user-select: all should be selected on single click 4 https://bugs.webkit.org/show_bug.cgi?id=117864 5 6 Reviewed by Darin Adler. 7 8 Set m_mouseDownMayStartSelect true even when the node cannot start selection 9 if the node was inside an element with -webkit-user-select: all. 10 11 Test: editing/selection/user-select-all-with-single-click.html 12 13 * page/EventHandler.cpp: 14 (WebCore::canMouseDownStartSelect): 15 1 16 2013-06-28 Ryosuke Niwa <rniwa@webkit.org> 2 17 -
trunk/Source/WebCore/dom/Position.h
r150954 r152198 192 192 static bool nodeIsUserSelectAll(const Node*); 193 193 static Node* rootUserSelectAllForNode(Node*); 194 #else 195 static bool nodeIsUserSelectAll(const Node*) { return false; } 196 static Node* rootUserSelectAllForNode(Node*) { return 0; } 194 197 #endif 195 198 static ContainerNode* findParent(const Node*); -
trunk/Source/WebCore/page/EventHandler.cpp
r152149 r152198 641 641 return true; 642 642 643 if (!node->canStartSelection()) 644 return false; 645 646 return true; 643 return node->canStartSelection() || Position::nodeIsUserSelectAll(node); 647 644 } 648 645
Note: See TracChangeset
for help on using the changeset viewer.