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

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

Issue 2220043002: Added PointerEvent.hasPointerCapture API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added a missing element interface. Created 4 years, 4 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
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 1473 matching lines...) Expand 10 before | Expand all | Expand 10 after
1484 { 1484 {
1485 // TODO(crbug.com/591387): This functionality should be per page not per fra me. 1485 // TODO(crbug.com/591387): This functionality should be per page not per fra me.
1486 m_pointerEventManager.setPointerCapture(pointerId, target); 1486 m_pointerEventManager.setPointerCapture(pointerId, target);
1487 } 1487 }
1488 1488
1489 void EventHandler::releasePointerCapture(int pointerId, EventTarget* target) 1489 void EventHandler::releasePointerCapture(int pointerId, EventTarget* target)
1490 { 1490 {
1491 m_pointerEventManager.releasePointerCapture(pointerId, target); 1491 m_pointerEventManager.releasePointerCapture(pointerId, target);
1492 } 1492 }
1493 1493
1494 bool EventHandler::hasPointerCapture(int pointerId, EventTarget* target)
1495 {
1496 return m_pointerEventManager.hasPointerCapture(pointerId, target);
1497 }
1498
1494 void EventHandler::elementRemoved(EventTarget* target) 1499 void EventHandler::elementRemoved(EventTarget* target)
1495 { 1500 {
1496 m_pointerEventManager.elementRemoved(target); 1501 m_pointerEventManager.elementRemoved(target);
1497 } 1502 }
1498 1503
1499 // TODO(mustaq): Make PE drive ME dispatch & bookkeeping in EventHandler. 1504 // TODO(mustaq): Make PE drive ME dispatch & bookkeeping in EventHandler.
1500 WebInputEventResult EventHandler::updatePointerTargetAndDispatchEvents(const Ato micString& mouseEventType, Node* targetNode, int clickCount, const PlatformMouse Event& mouseEvent) 1505 WebInputEventResult EventHandler::updatePointerTargetAndDispatchEvents(const Ato micString& mouseEventType, Node* targetNode, int clickCount, const PlatformMouse Event& mouseEvent)
1501 { 1506 {
1502 ASSERT(mouseEventType == EventTypeNames::mousedown 1507 ASSERT(mouseEventType == EventTypeNames::mousedown
1503 || mouseEventType == EventTypeNames::mousemove 1508 || mouseEventType == EventTypeNames::mousemove
(...skipping 1083 matching lines...) Expand 10 before | Expand all | Expand 10 after
2587 2592
2588 FrameHost* EventHandler::frameHost() const 2593 FrameHost* EventHandler::frameHost() const
2589 { 2594 {
2590 if (!m_frame->page()) 2595 if (!m_frame->page())
2591 return nullptr; 2596 return nullptr;
2592 2597
2593 return &m_frame->page()->frameHost(); 2598 return &m_frame->page()->frameHost();
2594 } 2599 }
2595 2600
2596 } // namespace blink 2601 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/input/EventHandler.h ('k') | third_party/WebKit/Source/core/input/PointerEventManager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698