| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 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 | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 167 case WebInputEvent::GestureLongTap: | 167 case WebInputEvent::GestureLongTap: |
| 168 return handler.handleGestureEvent(static_cast<const WebGestureEvent&>(ev
ent)); | 168 return handler.handleGestureEvent(static_cast<const WebGestureEvent&>(ev
ent)); |
| 169 | 169 |
| 170 case WebInputEvent::TouchStart: | 170 case WebInputEvent::TouchStart: |
| 171 case WebInputEvent::TouchMove: | 171 case WebInputEvent::TouchMove: |
| 172 case WebInputEvent::TouchEnd: | 172 case WebInputEvent::TouchEnd: |
| 173 case WebInputEvent::TouchCancel: | 173 case WebInputEvent::TouchCancel: |
| 174 if (!root || !root->view()) | 174 if (!root || !root->view()) |
| 175 return false; | 175 return false; |
| 176 return handler.handleTouchEvent(*root, static_cast<const WebTouchEvent&>
(event)); | 176 return handler.handleTouchEvent(*root, static_cast<const WebTouchEvent&>
(event)); |
| 177 | |
| 178 case WebInputEvent::GesturePinchBegin: | 177 case WebInputEvent::GesturePinchBegin: |
| 179 case WebInputEvent::GesturePinchEnd: | 178 case WebInputEvent::GesturePinchEnd: |
| 180 case WebInputEvent::GesturePinchUpdate: | 179 case WebInputEvent::GesturePinchUpdate: |
| 181 // FIXME: Once PlatformGestureEvent is updated to support pinch, this | 180 // Touchscreen pinch events are currently not handled in main thread. On
ce they are, |
| 182 // should call handleGestureEvent, just like it currently does for | 181 // these should be passed to |handleGestureEvent| similar to gesture scr
oll events. |
| 183 // gesture scroll. | |
| 184 return false; | 182 return false; |
| 185 | |
| 186 default: | 183 default: |
| 187 return false; | 184 return false; |
| 188 } | 185 } |
| 189 } | 186 } |
| 190 | 187 |
| 191 // ---------------------------------------------------------------- | 188 // ---------------------------------------------------------------- |
| 192 // Default handlers for PageWidgetEventHandler | 189 // Default handlers for PageWidgetEventHandler |
| 193 | 190 |
| 194 void PageWidgetEventHandler::handleMouseMove(LocalFrame& mainFrame, const WebMou
seEvent& event) | 191 void PageWidgetEventHandler::handleMouseMove(LocalFrame& mainFrame, const WebMou
seEvent& event) |
| 195 { | 192 { |
| (...skipping 19 matching lines...) Expand all Loading... |
| 215 { | 212 { |
| 216 return mainFrame.eventHandler().handleWheelEvent(PlatformWheelEventBuilder(m
ainFrame.view(), event)); | 213 return mainFrame.eventHandler().handleWheelEvent(PlatformWheelEventBuilder(m
ainFrame.view(), event)); |
| 217 } | 214 } |
| 218 | 215 |
| 219 bool PageWidgetEventHandler::handleTouchEvent(LocalFrame& mainFrame, const WebTo
uchEvent& event) | 216 bool PageWidgetEventHandler::handleTouchEvent(LocalFrame& mainFrame, const WebTo
uchEvent& event) |
| 220 { | 217 { |
| 221 return mainFrame.eventHandler().handleTouchEvent(PlatformTouchEventBuilder(m
ainFrame.view(), event)); | 218 return mainFrame.eventHandler().handleTouchEvent(PlatformTouchEventBuilder(m
ainFrame.view(), event)); |
| 222 } | 219 } |
| 223 | 220 |
| 224 } // namespace blink | 221 } // namespace blink |
| OLD | NEW |