| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2001 Peter Kelly (pmk@post.com) | 2 * Copyright (C) 2001 Peter Kelly (pmk@post.com) |
| 3 * Copyright (C) 2001 Tobias Anton (anton@stud.fbi.fh-darmstadt.de) | 3 * Copyright (C) 2001 Tobias Anton (anton@stud.fbi.fh-darmstadt.de) |
| 4 * Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) | 4 * Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) |
| 5 * Copyright (C) 2003, 2005, 2006, 2008 Apple Inc. All rights reserved. | 5 * Copyright (C) 2003, 2005, 2006, 2008 Apple Inc. All rights reserved. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 ASSERT(event.type() == PlatformEvent::MouseMoved || event.button() != NoButt
on); | 42 ASSERT(event.type() == PlatformEvent::MouseMoved || event.button() != NoButt
on); |
| 43 | 43 |
| 44 bool isMouseEnterOrLeave = eventType == EventTypeNames::mouseenter || eventT
ype == EventTypeNames::mouseleave; | 44 bool isMouseEnterOrLeave = eventType == EventTypeNames::mouseenter || eventT
ype == EventTypeNames::mouseleave; |
| 45 bool isCancelable = !isMouseEnterOrLeave; | 45 bool isCancelable = !isMouseEnterOrLeave; |
| 46 bool isBubbling = !isMouseEnterOrLeave; | 46 bool isBubbling = !isMouseEnterOrLeave; |
| 47 | 47 |
| 48 return MouseEvent::create( | 48 return MouseEvent::create( |
| 49 eventType, isBubbling, isCancelable, view, | 49 eventType, isBubbling, isCancelable, view, |
| 50 detail, event.globalPosition().x(), event.globalPosition().y(), event.po
sition().x(), event.position().y(), | 50 detail, event.globalPosition().x(), event.globalPosition().y(), event.po
sition().x(), event.position().y(), |
| 51 event.movementDelta().x(), event.movementDelta().y(), | 51 event.movementDelta().x(), event.movementDelta().y(), |
| 52 event.modifiers(), event.button(), | 52 event.getModifiers(), event.button(), |
| 53 platformModifiersToButtons(event.modifiers()), | 53 platformModifiersToButtons(event.getModifiers()), |
| 54 relatedTarget, event.timestamp(), event.syntheticEventType()); | 54 relatedTarget, event.timestamp(), event.getSyntheticEventType()); |
| 55 } | 55 } |
| 56 | 56 |
| 57 PassRefPtrWillBeRawPtr<MouseEvent> MouseEvent::create(const AtomicString& type,
bool canBubble, bool cancelable, PassRefPtrWillBeRawPtr<AbstractView> view, | 57 PassRefPtrWillBeRawPtr<MouseEvent> MouseEvent::create(const AtomicString& type,
bool canBubble, bool cancelable, PassRefPtrWillBeRawPtr<AbstractView> view, |
| 58 int detail, int screenX, int screenY, int windowX, int windowY, | 58 int detail, int screenX, int screenY, int windowX, int windowY, |
| 59 int movementX, int movementY, | 59 int movementX, int movementY, |
| 60 PlatformEvent::Modifiers modifiers, | 60 PlatformEvent::Modifiers modifiers, |
| 61 short button, unsigned short buttons, | 61 short button, unsigned short buttons, |
| 62 PassRefPtrWillBeRawPtr<EventTarget> relatedTarget, | 62 PassRefPtrWillBeRawPtr<EventTarget> relatedTarget, |
| 63 double platformTimeStamp, | 63 double platformTimeStamp, |
| 64 PlatformMouseEvent::SyntheticEventType syntheticEventType) | 64 PlatformMouseEvent::SyntheticEventType syntheticEventType) |
| (...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 302 doubleClickEvent->setTrusted(mouseEvent.isTrusted()); | 302 doubleClickEvent->setTrusted(mouseEvent.isTrusted()); |
| 303 if (mouseEvent.defaultHandled()) | 303 if (mouseEvent.defaultHandled()) |
| 304 doubleClickEvent->setDefaultHandled(); | 304 doubleClickEvent->setDefaultHandled(); |
| 305 DispatchEventResult doubleClickDispatchResult = EventDispatcher::dispatchEve
nt(dispatcher.node(), MouseEventDispatchMediator::create(doubleClickEvent)); | 305 DispatchEventResult doubleClickDispatchResult = EventDispatcher::dispatchEve
nt(dispatcher.node(), MouseEventDispatchMediator::create(doubleClickEvent)); |
| 306 if (doubleClickDispatchResult != DispatchEventResult::NotCanceled) | 306 if (doubleClickDispatchResult != DispatchEventResult::NotCanceled) |
| 307 return doubleClickDispatchResult; | 307 return doubleClickDispatchResult; |
| 308 return dispatchResult; | 308 return dispatchResult; |
| 309 } | 309 } |
| 310 | 310 |
| 311 } // namespace blink | 311 } // namespace blink |
| OLD | NEW |