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

Unified Diff: ios/chrome/browser/ui/ntp/new_tab_page_bar.mm

Issue 2610923005: Replace ObjCPropertyReleaser with ReleaseProperties() project-wide. (Closed)
Patch Set: weak -> assign Created 3 years, 11 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/ntp/new_tab_page_bar.mm
diff --git a/ios/chrome/browser/ui/ntp/new_tab_page_bar.mm b/ios/chrome/browser/ui/ntp/new_tab_page_bar.mm
index 760902a83eec023a970b8b6a8d630b6b56e181e6..5d9a7fdeb7586440cd5c53c9abcc060ce4c9c183 100644
--- a/ios/chrome/browser/ui/ntp/new_tab_page_bar.mm
+++ b/ios/chrome/browser/ui/ntp/new_tab_page_bar.mm
@@ -8,7 +8,7 @@
#include <cmath>
#include "base/logging.h"
-#include "base/mac/objc_property_releaser.h"
+#include "base/mac/objc_release_properties.h"
#include "base/mac/scoped_nsobject.h"
#import "ios/chrome/browser/ui/bookmarks/bookmark_utils_ios.h"
#import "ios/chrome/browser/ui/ntp/new_tab_page_bar_button.h"
@@ -36,7 +36,6 @@ const int kNumberOfTabsIncognito = 2;
}
@property(nonatomic, readwrite, retain) NSArray* buttons;
-@property(nonatomic, readwrite, retain) UIButton* popupButton;
- (void)setup;
- (void)calculateButtonWidth;
@@ -46,13 +45,9 @@ const int kNumberOfTabsIncognito = 2;
@end
@implementation NewTabPageBar {
- // Tabbar buttons.
- NSArray* buttons_; // UIButton
- NSArray* items_; // NewTabPageBarItem
- // Which button is currently selected.
+ NSArray* buttons_;
+ NSArray* items_;
NSUInteger selectedIndex_;
- // Popup button helper, for iPhone labels.
- UIButton* popupButton_;
// Don't allow tabbar animations on startup, only after first tap.
BOOL canAnimate_;
id<NewTabPageBarDelegate> delegate_; // weak
@@ -66,13 +61,10 @@ const int kNumberOfTabsIncognito = 2;
CGFloat buttonWidth_;
// Percentage overlay sits over tab bar buttons.
CGFloat overlayPercentage_;
-
- base::mac::ObjCPropertyReleaser propertyReleaser_NewTabPageBar_;
}
@synthesize items = items_;
@synthesize selectedIndex = selectedIndex_;
-@synthesize popupButton = popupButton_;
@synthesize buttons = buttons_;
@synthesize delegate = delegate_;
@synthesize overlayPercentage = overlayPercentage_;
@@ -94,7 +86,6 @@ const int kNumberOfTabsIncognito = 2;
}
- (void)setup {
- propertyReleaser_NewTabPageBar_.Init(self, [NewTabPageBar class]);
self.selectedIndex = NSNotFound;
canAnimate_ = NO;
self.autoresizingMask =
@@ -133,6 +124,11 @@ const int kNumberOfTabsIncognito = 2;
self.contentMode = UIViewContentModeRedraw;
}
+- (void)dealloc {
+ base::mac::ReleaseProperties(self);
+ [super dealloc];
+}
+
- (void)layoutSubviews {
[super layoutSubviews];

Powered by Google App Engine
This is Rietveld 408576698