Changeset 55353 in webkit
- Timestamp:
- Feb 27, 2010, 4:39:27 AM (15 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r55351 r55353 1 2010-02-27 Dan Bernstein <mitz@apple.com> 2 3 Reviewed by Maciej Stachowiak. 4 5 <rdar://problem/7696607> Links do not respect -webkit-user-drag: none 6 https://bugs.webkit.org/show_bug.cgi?id=35475 7 8 * fast/css/user-drag-none-expected.txt: Added. 9 * fast/css/user-drag-none.html: Added. 10 1 11 2010-02-27 Xan Lopez <xlopez@igalia.com> 2 12 -
trunk/WebCore/ChangeLog
r55352 r55353 1 2010-02-27 Dan Bernstein <mitz@apple.com> 2 3 Reviewed by Maciej Stachowiak. 4 5 <rdar://problem/7696607> Links do not respect -webkit-user-drag: none 6 https://bugs.webkit.org/show_bug.cgi?id=35475 7 8 Test: fast/css/user-drag-none.html 9 10 * page/DragController.cpp: 11 (WebCore::DragController::mayStartDragAtEventLocation): Added a node 12 parameter. The image drag check is done against the node, rather than 13 than against the hit test result. This prevents a non-draggable image 14 with an auto-draggable ancestor from being dragged alone. The link drag 15 check now ignores links that are -webkit-user-drag: none. 16 * page/DragController.h: 17 * page/EventHandler.cpp: 18 (WebCore::EventHandler::shouldDragAutoNode): Pass the current node 19 to mayStartDragAtEventLocation(). 20 1 21 2010-02-27 Pavel Feldman <pfeldman@chromium.org> 2 22 -
trunk/WebCore/page/DragController.cpp
r55029 r55353 513 513 } 514 514 515 bool DragController::mayStartDragAtEventLocation(const Frame* frame, const IntPoint& framePos )515 bool DragController::mayStartDragAtEventLocation(const Frame* frame, const IntPoint& framePos, Node* node) 516 516 { 517 517 ASSERT(frame); … … 524 524 525 525 mouseDownTarget = frame->eventHandler()->hitTestResultAtPoint(framePos, true); 526 if (node) 527 mouseDownTarget.setInnerNonSharedNode(node); 526 528 527 529 if (mouseDownTarget.image() … … 533 535 if (!mouseDownTarget.absoluteLinkURL().isEmpty() 534 536 && m_dragSourceAction & DragSourceActionLink 535 && mouseDownTarget.isLiveLink()) 537 && mouseDownTarget.isLiveLink() 538 && mouseDownTarget.URLElement()->renderer() && mouseDownTarget.URLElement()->renderer()->style()->userDrag() != DRAG_NONE) 536 539 return true; 537 540 … … 541 544 542 545 return false; 543 544 546 } 545 547 -
trunk/WebCore/page/DragController.h
r50810 r55353 78 78 DragSourceAction delegateDragSourceAction(const IntPoint& pagePoint); 79 79 80 bool mayStartDragAtEventLocation(const Frame*, const IntPoint& framePos );80 bool mayStartDragAtEventLocation(const Frame*, const IntPoint& framePos, Node*); 81 81 void dragEnded(); 82 82 -
trunk/WebCore/page/EventHandler.cpp
r55287 r55353 2218 2218 return false; 2219 2219 Page* page = m_frame->page(); 2220 return page && page->dragController()->mayStartDragAtEventLocation(m_frame, point );2220 return page && page->dragController()->mayStartDragAtEventLocation(m_frame, point, node); 2221 2221 } 2222 2222
Note:
See TracChangeset
for help on using the changeset viewer.