| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 IOS_WEB_VIEW_PUBLIC_CWV_SCROLL_VIEW_DELEGATE_H_ | 5 #ifndef IOS_WEB_VIEW_PUBLIC_CWV_SCROLL_VIEW_DELEGATE_H_ |
| 6 #define IOS_WEB_VIEW_PUBLIC_CWV_SCROLL_VIEW_DELEGATE_H_ | 6 #define IOS_WEB_VIEW_PUBLIC_CWV_SCROLL_VIEW_DELEGATE_H_ |
| 7 | 7 |
| 8 #import <CoreGraphics/CoreGraphics.h> | 8 #import <CoreGraphics/CoreGraphics.h> |
| 9 | 9 |
| 10 #import "cwv_export.h" |
| 11 |
| 10 @class CWVScrollView; | 12 @class CWVScrollView; |
| 11 | 13 |
| 12 // Delegete for CWVScrollView. | 14 // Delegete for CWVScrollView. |
| 13 // | 15 // |
| 14 // These methods are forwarded from the internal UIScrollViewDelegate. Please | 16 // These methods are forwarded from the internal UIScrollViewDelegate. Please |
| 15 // see the <UIKit/UIScrollViewDelegate.h> documentation for details about the | 17 // see the <UIKit/UIScrollViewDelegate.h> documentation for details about the |
| 16 // following methods. | 18 // following methods. |
| 17 CWV_EXPORT | 19 CWV_EXPORT |
| 18 @protocol CWVScrollViewDelegate<NSObject> | 20 @protocol CWVScrollViewDelegate<NSObject> |
| 19 @optional | 21 @optional |
| 20 - (void)scrollViewWillBeginDragging:(CWVScrollView*)scrollView; | 22 - (void)scrollViewWillBeginDragging:(CWVScrollView*)scrollView; |
| 21 - (void)scrollViewWillEndDragging:(CWVScrollView*)scrollView | 23 - (void)scrollViewWillEndDragging:(CWVScrollView*)scrollView |
| 22 withVelocity:(CGPoint)velocity | 24 withVelocity:(CGPoint)velocity |
| 23 targetContentOffset:(inout CGPoint*)targetContentOffset; | 25 targetContentOffset:(inout CGPoint*)targetContentOffset; |
| 24 - (void)scrollViewDidScroll:(CWVScrollView*)scrollView; | 26 - (void)scrollViewDidScroll:(CWVScrollView*)scrollView; |
| 25 - (void)scrollViewDidEndDecelerating:(CWVScrollView*)scrollView; | 27 - (void)scrollViewDidEndDecelerating:(CWVScrollView*)scrollView; |
| 26 | 28 |
| 27 // The equivalent in UIScrollViewDelegate also takes a parameter (UIView*)view, | 29 // The equivalent in UIScrollViewDelegate also takes a parameter (UIView*)view, |
| 28 // but CWVScrollViewDelegate doesn't expose it for flexibility of future | 30 // but CWVScrollViewDelegate doesn't expose it for flexibility of future |
| 29 // implementation. | 31 // implementation. |
| 30 - (void)scrollViewWillBeginZooming:(CWVScrollView*)webViewScrollViewProxy; | 32 - (void)scrollViewWillBeginZooming:(CWVScrollView*)webViewScrollViewProxy; |
| 31 @end | 33 @end |
| 32 | 34 |
| 33 #endif // IOS_WEB_VIEW_PUBLIC_CWV_SCROLL_VIEW_DELEGATE_H_ | 35 #endif // IOS_WEB_VIEW_PUBLIC_CWV_SCROLL_VIEW_DELEGATE_H_ |
| OLD | NEW |