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

Side by Side Diff: third_party/WebKit/Source/core/input/EventHandler.cpp

Issue 2326653003: Conditional hittesting & sending boundary events for captured pointer events (Closed)
Patch Set: Fix double function call Created 4 years, 3 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/input/PointerEventManager.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed.
3 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) 3 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org)
4 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies) 4 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies)
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 1366 matching lines...) Expand 10 before | Expand all | Expand 10 after
1377 1377
1378 return m_frame->document()->prepareMouseEvent(request, contentPointFromRootF rame(m_frame, mev.position()), mev); 1378 return m_frame->document()->prepareMouseEvent(request, contentPointFromRootF rame(m_frame, mev.position()), mev);
1379 } 1379 }
1380 1380
1381 Node* EventHandler::updateMouseEventTargetNode(Node* targetNode, 1381 Node* EventHandler::updateMouseEventTargetNode(Node* targetNode,
1382 const PlatformMouseEvent& mouseEvent) 1382 const PlatformMouseEvent& mouseEvent)
1383 { 1383 {
1384 Node* newNodeUnderMouse = targetNode; 1384 Node* newNodeUnderMouse = targetNode;
1385 1385
1386 // If we're capturing, we always go right to that node. 1386 // If we're capturing, we always go right to that node.
1387 if (EventTarget* mousePointerCapturingNode = m_pointerEventManager->getMouse CapturingNode()) { 1387 EventTarget* mousePointerCapturingNode = m_pointerEventManager->getMouseCapt uringNode();
1388 if (mousePointerCapturingNode
1389 && !RuntimeEnabledFeatures::pointerEventV1SpecCapturingEnabled()) {
1388 newNodeUnderMouse = mousePointerCapturingNode->toNode(); 1390 newNodeUnderMouse = mousePointerCapturingNode->toNode();
1389 DCHECK(newNodeUnderMouse); 1391 DCHECK(newNodeUnderMouse);
1390 } else if (m_capturingMouseEventsNode) { 1392 } else if (m_capturingMouseEventsNode) {
1391 newNodeUnderMouse = m_capturingMouseEventsNode.get(); 1393 newNodeUnderMouse = m_capturingMouseEventsNode.get();
1392 } else { 1394 } else {
1393 // If the target node is a text node, dispatch on the parent node - rdar ://4196646 1395 // If the target node is a text node, dispatch on the parent node - rdar ://4196646
1394 if (newNodeUnderMouse && newNodeUnderMouse->isTextNode()) 1396 if (newNodeUnderMouse && newNodeUnderMouse->isTextNode())
1395 newNodeUnderMouse = FlatTreeTraversal::parent(*newNodeUnderMouse); 1397 newNodeUnderMouse = FlatTreeTraversal::parent(*newNodeUnderMouse);
1396 } 1398 }
1397 Node* lastNodeUnderMouse = m_nodeUnderMouse; 1399 Node* lastNodeUnderMouse = m_nodeUnderMouse;
(...skipping 1160 matching lines...) Expand 10 before | Expand all | Expand 10 after
2558 2560
2559 FrameHost* EventHandler::frameHost() const 2561 FrameHost* EventHandler::frameHost() const
2560 { 2562 {
2561 if (!m_frame->page()) 2563 if (!m_frame->page())
2562 return nullptr; 2564 return nullptr;
2563 2565
2564 return &m_frame->page()->frameHost(); 2566 return &m_frame->page()->frameHost();
2565 } 2567 }
2566 2568
2567 } // namespace blink 2569 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/input/PointerEventManager.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698