OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #import "ios/web/web_state/ui/crw_touch_tracking_recognizer.h" | 5 #import "ios/web/web_state/ui/crw_touch_tracking_recognizer.h" |
6 | 6 |
| 7 #if !defined(__has_feature) || !__has_feature(objc_arc) |
| 8 #error "This file requires ARC support." |
| 9 #endif |
| 10 |
7 @interface CRWTouchTrackingRecognizer () <UIGestureRecognizerDelegate> { | 11 @interface CRWTouchTrackingRecognizer () <UIGestureRecognizerDelegate> { |
8 id<CRWTouchTrackingDelegate> _delegate; // weak | 12 id<CRWTouchTrackingDelegate> __weak _delegate; |
9 } | 13 } |
10 @end | 14 @end |
11 | 15 |
12 @implementation CRWTouchTrackingRecognizer | 16 @implementation CRWTouchTrackingRecognizer |
13 | 17 |
14 @synthesize touchTrackingDelegate = _delegate; | 18 @synthesize touchTrackingDelegate = _delegate; |
15 | 19 |
16 - (id)initWithDelegate:(id<CRWTouchTrackingDelegate>)delegate { | 20 - (id)initWithDelegate:(id<CRWTouchTrackingDelegate>)delegate { |
17 if ((self = [super init])) { | 21 if ((self = [super init])) { |
18 _delegate = delegate; | 22 _delegate = delegate; |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 #pragma mark - | 55 #pragma mark - |
52 #pragma mark UIGestureRecognizerDelegate Method | 56 #pragma mark UIGestureRecognizerDelegate Method |
53 | 57 |
54 - (BOOL)gestureRecognizer:(UIGestureRecognizer*)gestureRecognizer | 58 - (BOOL)gestureRecognizer:(UIGestureRecognizer*)gestureRecognizer |
55 shouldRecognizeSimultaneouslyWithGestureRecognizer: | 59 shouldRecognizeSimultaneouslyWithGestureRecognizer: |
56 (UIGestureRecognizer*)otherGestureRecognizer { | 60 (UIGestureRecognizer*)otherGestureRecognizer { |
57 return YES; | 61 return YES; |
58 } | 62 } |
59 | 63 |
60 @end | 64 @end |
OLD | NEW |