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

Unified Diff: ios/chrome/browser/ui/omnibox/omnibox_popup_view_ios.mm

Issue 2707963002: [ObjC ARC] Converts ios/chrome/browser/ui/omnibox:omnibox_internal to ARC. (Closed)
Patch Set: ARC in new code Created 3 years, 9 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
Index: ios/chrome/browser/ui/omnibox/omnibox_popup_view_ios.mm
diff --git a/ios/chrome/browser/ui/omnibox/omnibox_popup_view_ios.mm b/ios/chrome/browser/ui/omnibox/omnibox_popup_view_ios.mm
index e975fe27ce753e253aa130fc5dcac4d841a70a83..d15dd359fd48acc21579d3fc29f0f30c44211fc2 100644
--- a/ios/chrome/browser/ui/omnibox/omnibox_popup_view_ios.mm
+++ b/ios/chrome/browser/ui/omnibox/omnibox_popup_view_ios.mm
@@ -30,6 +30,10 @@
#include "net/url_request/url_request_context_getter.h"
#include "ui/gfx/geometry/rect.h"
+#if !defined(__has_feature) || !__has_feature(objc_arc)
+#error "This file requires ARC support."
+#endif
+
namespace {
const CGFloat kExpandAnimationDuration = 0.1;
const CGFloat kCollapseAnimationDuration = 0.05;
@@ -73,8 +77,8 @@ OmniboxPopupViewIOS::OmniboxPopupViewIOS(OmniboxViewIOS* edit_view,
[popupView_ addSubview:popupControllerView];
if (IsIPadIdiom()) {
[popupView_ setAutoresizingMask:UIViewAutoresizingFlexibleWidth];
- base::scoped_nsobject<UIImageView> shadowView([[UIImageView alloc]
- initWithImage:NativeImage(IDR_IOS_TOOLBAR_SHADOW_FULL_BLEED)]);
+ UIImageView* shadowView = [[UIImageView alloc]
+ initWithImage:NativeImage(IDR_IOS_TOOLBAR_SHADOW_FULL_BLEED)];
[shadowView setUserInteractionEnabled:NO];
[shadowView setTranslatesAutoresizingMaskIntoConstraints:NO];
[popupView_ addSubview:shadowView];
@@ -99,8 +103,7 @@ OmniboxPopupViewIOS::OmniboxPopupViewIOS(OmniboxViewIOS* edit_view,
} else {
// Add a white background to prevent seing the logo scroll through the
// omnibox.
- base::scoped_nsobject<UIView> whiteBackground(
- [[UIView alloc] initWithFrame:CGRectZero]);
+ UIView* whiteBackground = [[UIView alloc] initWithFrame:CGRectZero];
[popupView_ addSubview:whiteBackground];
[whiteBackground setBackgroundColor:[UIColor whiteColor]];
« no previous file with comments | « ios/chrome/browser/ui/omnibox/omnibox_popup_view_ios.h ('k') | ios/chrome/browser/ui/omnibox/omnibox_text_field_ios.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698