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

Unified Diff: chrome/browser/ui/cocoa/infobars/confirm_infobar_controller.mm

Issue 22694006: Infobar system refactor. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 years, 2 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: chrome/browser/ui/cocoa/infobars/confirm_infobar_controller.mm
===================================================================
--- chrome/browser/ui/cocoa/infobars/confirm_infobar_controller.mm (revision 226624)
+++ chrome/browser/ui/cocoa/infobars/confirm_infobar_controller.mm (working copy)
@@ -137,10 +137,13 @@
@end
-InfoBar* ConfirmInfoBarDelegate::CreateInfoBar(InfoBarService* owner) {
- scoped_ptr<InfoBarCocoa> infobar(new InfoBarCocoa(owner, this));
+// static
+scoped_ptr<InfoBar> ConfirmInfoBarDelegate::CreateInfoBar(
+ scoped_ptr<ConfirmInfoBarDelegate> delegate) {
+ scoped_ptr<InfoBarCocoa> infobar(
+ new InfoBarCocoa(delegate.PassAs<InfoBarDelegate>()));
base::scoped_nsobject<ConfirmInfoBarController> controller(
[[ConfirmInfoBarController alloc] initWithInfoBar:infobar.get()]);
infobar->set_controller(controller);
- return infobar.release();
+ return infobar.PassAs<InfoBar>();
}

Powered by Google App Engine
This is Rietveld 408576698