Ignore:
Timestamp:
Oct 1, 2013, 9:20:06 PM (12 years ago)
Author:
[email protected]
Message:

Move mouse event dispatch from Node to Element.
<https://webkit.org/b/122203>

Reviewed by Anders Carlsson.

We never dispatch mouse events on text or other non-element nodes,
so move the related logic to using Element.

Node::dispatchMouseEvent() moves to Element. I also changed the
relatedTarget argument to be an Element* since the related target
is never a Node either.

Most of this patch is *Node -> *Element renames in EventHandler.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/rendering/RenderEmbeddedObject.cpp

    r156397 r156761  
    616616        m_mouseDownWasInUnavailablePluginIndicator = isInUnavailablePluginIndicator(mouseEvent);
    617617        if (m_mouseDownWasInUnavailablePluginIndicator) {
    618             frame().eventHandler().setCapturingMouseEventsNode(&element);
     618            frame().eventHandler().setCapturingMouseEventsElement(&element);
    619619            element.setIsCapturingMouseEvents(true);
    620620            setUnavailablePluginIndicatorIsPressed(true);
     
    624624    if (event->type() == eventNames().mouseupEvent && static_cast<MouseEvent*>(event)->button() == LeftButton) {
    625625        if (m_unavailablePluginIndicatorIsPressed) {
    626             frame().eventHandler().setCapturingMouseEventsNode(0);
     626            frame().eventHandler().setCapturingMouseEventsElement(nullptr);
    627627            element.setIsCapturingMouseEvents(false);
    628628            setUnavailablePluginIndicatorIsPressed(false);
Note: See TracChangeset for help on using the changeset viewer.