| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_MAC_DELEGATE_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_MAC_DELEGATE_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_MAC_DELEGATE_H_ | 6 #define CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_MAC_DELEGATE_H_ |
| 7 | 7 |
| 8 #import <Cocoa/Cocoa.h> | 8 #import <Cocoa/Cocoa.h> |
| 9 | 9 |
| 10 namespace blink { | 10 namespace blink { |
| 11 class WebGestureEvent; |
| 11 class WebMouseWheelEvent; | 12 class WebMouseWheelEvent; |
| 12 } | 13 } |
| 13 | 14 |
| 14 // This protocol is used as a delegate for the NSView class used in the | 15 // This protocol is used as a delegate for the NSView class used in the |
| 15 // hierarchy. There are two ways to extend the view: | 16 // hierarchy. There are two ways to extend the view: |
| 16 // - Implement the methods listed in the protocol below. | 17 // - Implement the methods listed in the protocol below. |
| 17 // - Implement any method, and if the view is requested to perform that method | 18 // - Implement any method, and if the view is requested to perform that method |
| 18 // and cannot, the delegate's implementation will be used. | 19 // and cannot, the delegate's implementation will be used. |
| 19 // | 20 // |
| 20 // Like any Objective-C delegate, it is not retained by the delegator object. | 21 // Like any Objective-C delegate, it is not retained by the delegator object. |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 // These methods control whether a given view is allowed to rubberband in the | 54 // These methods control whether a given view is allowed to rubberband in the |
| 54 // given direction. This is inversely related to whether the view is allowed to | 55 // given direction. This is inversely related to whether the view is allowed to |
| 55 // 2-finger history swipe in the given direction. | 56 // 2-finger history swipe in the given direction. |
| 56 - (BOOL)canRubberbandLeft:(NSView*)view; | 57 - (BOOL)canRubberbandLeft:(NSView*)view; |
| 57 - (BOOL)canRubberbandRight:(NSView*)view; | 58 - (BOOL)canRubberbandRight:(NSView*)view; |
| 58 | 59 |
| 59 // The browser process received an ACK from the renderer after it processed | 60 // The browser process received an ACK from the renderer after it processed |
| 60 // |event|. | 61 // |event|. |
| 61 - (void)rendererHandledWheelEvent:(const blink::WebMouseWheelEvent&)event | 62 - (void)rendererHandledWheelEvent:(const blink::WebMouseWheelEvent&)event |
| 62 consumed:(BOOL)consumed; | 63 consumed:(BOOL)consumed; |
| 64 - (void)rendererHandledGestureScrollEvent:(const blink::WebGestureEvent&)event |
| 65 consumed:(BOOL)consumed; |
| 63 @end | 66 @end |
| 64 | 67 |
| 65 #endif // CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_MAC_DELEGATE_H_ | 68 #endif // CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_MAC_DELEGATE_H_ |
| OLD | NEW |