Index: trunk/src/chrome/browser/ui/startup/autolaunch_prompt_win.cc |
=================================================================== |
--- trunk/src/chrome/browser/ui/startup/autolaunch_prompt_win.cc (revision 238401) |
+++ trunk/src/chrome/browser/ui/startup/autolaunch_prompt_win.cc (working copy) |
@@ -11,7 +11,6 @@ |
#include "chrome/browser/auto_launch_trial.h" |
#include "chrome/browser/first_run/first_run.h" |
#include "chrome/browser/infobars/confirm_infobar_delegate.h" |
-#include "chrome/browser/infobars/infobar.h" |
#include "chrome/browser/infobars/infobar_service.h" |
#include "chrome/browser/profiles/profile.h" |
#include "chrome/browser/ui/browser.h" |
@@ -37,12 +36,12 @@ |
// The delegate for the infobar shown when Chrome is auto-launched. |
class AutolaunchInfoBarDelegate : public ConfirmInfoBarDelegate { |
public: |
- // Creates an autolaunch infobar and delegate and adds the infobar to |
- // |infobar_service|. |
+ // Creates an autolaunch infobar delegate and adds it to |infobar_service|. |
static void Create(InfoBarService* infobar_service, Profile* profile); |
private: |
- explicit AutolaunchInfoBarDelegate(Profile* profile); |
+ AutolaunchInfoBarDelegate(InfoBarService* infobar_service, |
+ Profile* profile); |
virtual ~AutolaunchInfoBarDelegate(); |
void set_should_expire() { should_expire_ = true; } |
@@ -71,14 +70,14 @@ |
// static |
void AutolaunchInfoBarDelegate::Create(InfoBarService* infobar_service, |
Profile* profile) { |
- infobar_service->AddInfoBar(ConfirmInfoBarDelegate::CreateInfoBar( |
- scoped_ptr<ConfirmInfoBarDelegate>( |
- new AutolaunchInfoBarDelegate(profile)))); |
+ infobar_service->AddInfoBar(scoped_ptr<InfoBarDelegate>( |
+ new AutolaunchInfoBarDelegate(infobar_service, profile))); |
} |
AutolaunchInfoBarDelegate::AutolaunchInfoBarDelegate( |
+ InfoBarService* infobar_service, |
Profile* profile) |
- : ConfirmInfoBarDelegate(), |
+ : ConfirmInfoBarDelegate(infobar_service), |
profile_(profile), |
should_expire_(false), |
weak_factory_(this) { |