| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 269 } | 269 } |
| 270 | 270 |
| 271 if (WebInputEvent::isTouchEventType(inputEvent.type)) { | 271 if (WebInputEvent::isTouchEventType(inputEvent.type)) { |
| 272 PlatformTouchEvent touchEvent = PlatformTouchEventBuilder(m_webViewImpl-
>mainFrameImpl()->frameView(), static_cast<const WebTouchEvent&>(inputEvent)); | 272 PlatformTouchEvent touchEvent = PlatformTouchEventBuilder(m_webViewImpl-
>mainFrameImpl()->frameView(), static_cast<const WebTouchEvent&>(inputEvent)); |
| 273 handled = handleTouchEvent(touchEvent); | 273 handled = handleTouchEvent(touchEvent); |
| 274 if (handled) | 274 if (handled) |
| 275 return true; | 275 return true; |
| 276 overlayMainFrame()->eventHandler().handleTouchEvent(touchEvent); | 276 overlayMainFrame()->eventHandler().handleTouchEvent(touchEvent); |
| 277 } | 277 } |
| 278 if (WebInputEvent::isKeyboardEventType(inputEvent.type)) { | 278 if (WebInputEvent::isKeyboardEventType(inputEvent.type)) { |
| 279 PlatformKeyboardEvent keyboardEvent = PlatformKeyboardEventBuilder(stati
c_cast<const WebKeyboardEvent&>(inputEvent)); | 279 overlayMainFrame()->eventHandler().keyEvent(static_cast<const WebKeyboar
dEvent&>(inputEvent)); |
| 280 overlayMainFrame()->eventHandler().keyEvent(keyboardEvent); | |
| 281 } | 280 } |
| 282 | 281 |
| 283 if (inputEvent.type == WebInputEvent::MouseWheel) { | 282 if (inputEvent.type == WebInputEvent::MouseWheel) { |
| 284 PlatformWheelEvent wheelEvent = PlatformWheelEventBuilder(m_webViewImpl-
>mainFrameImpl()->frameView(), static_cast<const WebMouseWheelEvent&>(inputEvent
)); | 283 PlatformWheelEvent wheelEvent = PlatformWheelEventBuilder(m_webViewImpl-
>mainFrameImpl()->frameView(), static_cast<const WebMouseWheelEvent&>(inputEvent
)); |
| 285 handled = overlayMainFrame()->eventHandler().handleWheelEvent(wheelEvent
) != WebInputEventResult::NotHandled; | 284 handled = overlayMainFrame()->eventHandler().handleWheelEvent(wheelEvent
) != WebInputEventResult::NotHandled; |
| 286 } | 285 } |
| 287 | 286 |
| 288 return handled; | 287 return handled; |
| 289 } | 288 } |
| 290 | 289 |
| (...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 813 | 812 |
| 814 void InspectorOverlay::initializeLayoutEditorIfNeeded(Node* node) | 813 void InspectorOverlay::initializeLayoutEditorIfNeeded(Node* node) |
| 815 { | 814 { |
| 816 if (m_inspectMode != InspectorDOMAgent::ShowLayoutEditor || !node || !node->
isElementNode() || !node->ownerDocument()->isActive() || !m_cssAgent || !m_domAg
ent) | 815 if (m_inspectMode != InspectorDOMAgent::ShowLayoutEditor || !node || !node->
isElementNode() || !node->ownerDocument()->isActive() || !m_cssAgent || !m_domAg
ent) |
| 817 return; | 816 return; |
| 818 m_layoutEditor = LayoutEditor::create(toElement(node), m_cssAgent, m_domAgen
t, &overlayMainFrame()->script()); | 817 m_layoutEditor = LayoutEditor::create(toElement(node), m_cssAgent, m_domAgen
t, &overlayMainFrame()->script()); |
| 819 toChromeClientImpl(m_webViewImpl->page()->chromeClient()).setCursorOverridde
n(true); | 818 toChromeClientImpl(m_webViewImpl->page()->chromeClient()).setCursorOverridde
n(true); |
| 820 } | 819 } |
| 821 | 820 |
| 822 } // namespace blink | 821 } // namespace blink |
| OLD | NEW |