OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2008, The Android Open Source Project | 2 * Copyright 2008, The Android Open Source Project |
3 * Copyright (C) 2012 Research In Motion Limited. All rights reserved. | 3 * Copyright (C) 2012 Research In Motion Limited. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above copyright | 10 * * Redistributions in binary form must reproduce the above copyright |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
75 m_screenLocation = IntPoint(screenX, screenY); | 75 m_screenLocation = IntPoint(screenX, screenY); |
76 m_ctrlKey = ctrlKey; | 76 m_ctrlKey = ctrlKey; |
77 m_altKey = altKey; | 77 m_altKey = altKey; |
78 m_shiftKey = shiftKey; | 78 m_shiftKey = shiftKey; |
79 m_metaKey = metaKey; | 79 m_metaKey = metaKey; |
80 initCoordinates(IntPoint(clientX, clientY)); | 80 initCoordinates(IntPoint(clientX, clientY)); |
81 } | 81 } |
82 | 82 |
83 const AtomicString& TouchEvent::interfaceName() const | 83 const AtomicString& TouchEvent::interfaceName() const |
84 { | 84 { |
85 return eventNames().interfaceForTouchEvent; | 85 return EventNames::TouchEvent; |
86 } | 86 } |
87 | 87 |
88 bool TouchEvent::isTouchEvent() const | 88 bool TouchEvent::isTouchEvent() const |
89 { | 89 { |
90 return true; | 90 return true; |
91 } | 91 } |
92 | 92 |
93 PassRefPtr<TouchEventDispatchMediator> TouchEventDispatchMediator::create(PassRe
fPtr<TouchEvent> touchEvent) | 93 PassRefPtr<TouchEventDispatchMediator> TouchEventDispatchMediator::create(PassRe
fPtr<TouchEvent> touchEvent) |
94 { | 94 { |
95 return adoptRef(new TouchEventDispatchMediator(touchEvent)); | 95 return adoptRef(new TouchEventDispatchMediator(touchEvent)); |
96 } | 96 } |
97 | 97 |
98 TouchEventDispatchMediator::TouchEventDispatchMediator(PassRefPtr<TouchEvent> to
uchEvent) | 98 TouchEventDispatchMediator::TouchEventDispatchMediator(PassRefPtr<TouchEvent> to
uchEvent) |
99 : EventDispatchMediator(touchEvent) | 99 : EventDispatchMediator(touchEvent) |
100 { | 100 { |
101 } | 101 } |
102 | 102 |
103 TouchEvent* TouchEventDispatchMediator::event() const | 103 TouchEvent* TouchEventDispatchMediator::event() const |
104 { | 104 { |
105 return toTouchEvent(EventDispatchMediator::event()); | 105 return toTouchEvent(EventDispatchMediator::event()); |
106 } | 106 } |
107 | 107 |
108 bool TouchEventDispatchMediator::dispatchEvent(EventDispatcher* dispatcher) cons
t | 108 bool TouchEventDispatchMediator::dispatchEvent(EventDispatcher* dispatcher) cons
t |
109 { | 109 { |
110 EventRetargeter::adjustForTouchEvent(dispatcher->node(), *event()); | 110 EventRetargeter::adjustForTouchEvent(dispatcher->node(), *event()); |
111 return dispatcher->dispatch(); | 111 return dispatcher->dispatch(); |
112 } | 112 } |
113 | 113 |
114 } // namespace WebCore | 114 } // namespace WebCore |
OLD | NEW |