Index: chrome/browser/ui/cocoa/tracking_area.mm |
diff --git a/chrome/browser/ui/cocoa/tracking_area.mm b/chrome/browser/ui/cocoa/tracking_area.mm |
index ac638b853f71536e4106261823218d8639964b2f..004695bc7dedd8b5d5d2ebee6fd75ed146ed6a57 100644 |
--- a/chrome/browser/ui/cocoa/tracking_area.mm |
+++ b/chrome/browser/ui/cocoa/tracking_area.mm |
@@ -68,29 +68,20 @@ |
@implementation CrTrackingArea |
- (id)initWithRect:(NSRect)rect |
- options:(NSTrackingAreaOptions)options |
- proxiedOwner:(id)owner |
- userInfo:(NSDictionary*)userInfo { |
+ options:(NSTrackingAreaOptions)options |
+ owner:(id)owner |
+ userInfo:(NSDictionary*)userInfo { |
scoped_nsobject<CrTrackingAreaOwnerProxy> ownerProxy( |
[[CrTrackingAreaOwnerProxy alloc] initWithOwner:owner]); |
- if ((self = static_cast<id>([super initWithRect:rect |
- options:options |
- owner:ownerProxy.get() |
- userInfo:userInfo]))) { |
+ if ((self = [super initWithRect:rect |
+ options:options |
+ owner:ownerProxy.get() |
+ userInfo:userInfo])) { |
ownerProxy_.swap(ownerProxy); |
} |
return self; |
} |
-- (NSTrackingArea*)initWithRect:(NSRect)rect |
- options:(NSTrackingAreaOptions)options |
- owner:(id)owner |
- userInfo:(NSDictionary*)userInfo { |
- [NSException raise:@"org.chromium.CrTrackingArea" |
- format:@"Cannot init a CrTrackingArea with NSTrackingArea's initializer"]; |
- return nil; |
-} |
- |
- (void)dealloc { |
[self clearOwner]; |
[[NSNotificationCenter defaultCenter] removeObserver:self]; |