| 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 10 matching lines...) Expand all Loading... |
| 21 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 21 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF | 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF |
| 23 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 23 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 24 */ | 24 */ |
| 25 | 25 |
| 26 #ifndef WebCompositorInputHandlerClient_h | 26 #ifndef WebCompositorInputHandlerClient_h |
| 27 #define WebCompositorInputHandlerClient_h | 27 #define WebCompositorInputHandlerClient_h |
| 28 | 28 |
| 29 namespace WebKit { | 29 namespace WebKit { |
| 30 | 30 |
| 31 struct WebActiveWheelFlingParameters; |
| 32 |
| 31 class WebCompositorInputHandlerClient { | 33 class WebCompositorInputHandlerClient { |
| 32 public: | 34 public: |
| 33 // Callbacks invoked from the compositor thread. | 35 // Callbacks invoked from the compositor thread. |
| 34 virtual void willShutdown() = 0; | 36 virtual void willShutdown() = 0; |
| 35 | 37 |
| 36 // Exactly one of the following two callbacks will be invoked after every ca
ll to WebCompositor::handleInputEvent(): | 38 // Exactly one of the following two callbacks will be invoked after every ca
ll to WebCompositor::handleInputEvent(): |
| 37 | 39 |
| 38 // Called when the WebCompositor handled the input event and no further proc
essing is required. | 40 // Called when the WebCompositor handled the input event and no further proc
essing is required. |
| 39 virtual void didHandleInputEvent() = 0; | 41 virtual void didHandleInputEvent() = 0; |
| 40 | 42 |
| 41 // Called when the WebCompositor did not handle the input event. If sendToWi
dget is true, the input event | 43 // Called when the WebCompositor did not handle the input event. If sendToWi
dget is true, the input event |
| 42 // should be forwarded to the WebWidget associated with this compositor for
further processing. | 44 // should be forwarded to the WebWidget associated with this compositor for
further processing. |
| 43 virtual void didNotHandleInputEvent(bool sendToWidget) = 0; | 45 virtual void didNotHandleInputEvent(bool sendToWidget) = 0; |
| 44 | 46 |
| 47 // Transfers an active wheel fling animation initiated by a previously handl
ed input event out to the client. |
| 48 // FIXME: Make pure virtual once implementation lands on Chromium side. |
| 49 virtual void transferActiveWheelFlingAnimation(const WebActiveWheelFlingPara
meters&) { } |
| 50 |
| 45 protected: | 51 protected: |
| 46 virtual ~WebCompositorInputHandlerClient() { } | 52 virtual ~WebCompositorInputHandlerClient() { } |
| 47 }; | 53 }; |
| 48 | 54 |
| 49 } // namespace WebKit | 55 } // namespace WebKit |
| 50 | 56 |
| 51 #endif | 57 #endif |
| OLD | NEW |