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

Side by Side Diff: chrome/browser/ui/cocoa/extensions/toolbar_actions_bar_bubble_mac.mm

Issue 1865213004: Convert //chrome/browser/ui from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "chrome/browser/ui/cocoa/extensions/toolbar_actions_bar_bubble_mac.h" 5 #import "chrome/browser/ui/cocoa/extensions/toolbar_actions_bar_bubble_mac.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/mac/foundation_util.h" 9 #include "base/mac/foundation_util.h"
10 #include "base/strings/sys_string_conversions.h" 10 #include "base/strings/sys_string_conversions.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 56
57 @implementation ToolbarActionsBarBubbleMac 57 @implementation ToolbarActionsBarBubbleMac
58 58
59 @synthesize actionButton = actionButton_; 59 @synthesize actionButton = actionButton_;
60 @synthesize itemList = itemList_; 60 @synthesize itemList = itemList_;
61 @synthesize dismissButton = dismissButton_; 61 @synthesize dismissButton = dismissButton_;
62 @synthesize learnMoreButton = learnMoreButton_; 62 @synthesize learnMoreButton = learnMoreButton_;
63 63
64 - (id)initWithParentWindow:(NSWindow*)parentWindow 64 - (id)initWithParentWindow:(NSWindow*)parentWindow
65 anchorPoint:(NSPoint)anchorPoint 65 anchorPoint:(NSPoint)anchorPoint
66 delegate:(scoped_ptr<ToolbarActionsBarBubbleDelegate>) 66 delegate:(std::unique_ptr<ToolbarActionsBarBubbleDelegate>)
67 delegate { 67 delegate {
68 base::scoped_nsobject<InfoBubbleWindow> window( 68 base::scoped_nsobject<InfoBubbleWindow> window(
69 [[InfoBubbleWindow alloc] 69 [[InfoBubbleWindow alloc]
70 initWithContentRect:ui::kWindowSizeDeterminedLater 70 initWithContentRect:ui::kWindowSizeDeterminedLater
71 styleMask:NSBorderlessWindowMask 71 styleMask:NSBorderlessWindowMask
72 backing:NSBackingStoreBuffered 72 backing:NSBackingStoreBuffered
73 defer:NO]); 73 defer:NO]);
74 if ((self = [super initWithWindow:window 74 if ((self = [super initWithWindow:window
75 parentWindow:parentWindow 75 parentWindow:parentWindow
76 anchoredAt:anchorPoint])) { 76 anchoredAt:anchorPoint])) {
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
334 } else { 334 } else {
335 DCHECK_EQ(sender, actionButton_); 335 DCHECK_EQ(sender, actionButton_);
336 action = ToolbarActionsBarBubbleDelegate::CLOSE_EXECUTE; 336 action = ToolbarActionsBarBubbleDelegate::CLOSE_EXECUTE;
337 } 337 }
338 acknowledged_ = YES; 338 acknowledged_ = YES;
339 delegate_->OnBubbleClosed(action); 339 delegate_->OnBubbleClosed(action);
340 [self close]; 340 [self close];
341 } 341 }
342 342
343 @end 343 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698