Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(952)

Unified Diff: ios/web/public/test/fakes/test_web_view_content_view.mm

Issue 2922973004: [ObjC ARC] Converts ios/web/public/test/fakes:fakes to ARC. (Closed)
Patch Set: scoped_nsobject in .h Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ios/web/public/test/fakes/test_web_state_observer_util.mm ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web/public/test/fakes/test_web_view_content_view.mm
diff --git a/ios/web/public/test/fakes/test_web_view_content_view.mm b/ios/web/public/test/fakes/test_web_view_content_view.mm
index a5c081616482f74708ca598e8198ef8176aef3f6..0c4506ac6b1eda4d2221e77493d25ca2a6b22c58 100644
--- a/ios/web/public/test/fakes/test_web_view_content_view.mm
+++ b/ios/web/public/test/fakes/test_web_view_content_view.mm
@@ -5,11 +5,14 @@
#import "ios/web/public/test/fakes/test_web_view_content_view.h"
#include "base/logging.h"
-#import "base/mac/scoped_nsobject.h"
+
+#if !defined(__has_feature) || !__has_feature(objc_arc)
+#error "This file requires ARC support."
+#endif
@interface TestWebViewContentView () {
- base::scoped_nsprotocol<id> _mockWebView;
- base::scoped_nsprotocol<id> _mockScrollView;
+ id _mockWebView;
+ id _mockScrollView;
}
@end
@@ -21,8 +24,8 @@
if (self) {
DCHECK(webView);
DCHECK(scrollView);
- _mockWebView.reset([webView retain]);
- _mockScrollView.reset([scrollView retain]);
+ _mockWebView = webView;
+ _mockScrollView = scrollView;
}
return self;
}
@@ -40,11 +43,11 @@
#pragma mark Accessors
- (UIScrollView*)scrollView {
- return static_cast<UIScrollView*>(_mockScrollView.get());
+ return static_cast<UIScrollView*>(_mockScrollView);
}
- (UIView*)webView {
- return static_cast<UIView*>(_mockWebView.get());
+ return static_cast<UIView*>(_mockWebView);
}
@end
« no previous file with comments | « ios/web/public/test/fakes/test_web_state_observer_util.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698