summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authortfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-02 23:35:58 +0000
committertfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-02 23:35:58 +0000
commitd75aba1dd9552b603fc713fd00927b28bfd824bf (patch)
tree9b259b9650bf2e2bc74a0e87407e0a72b04affc8 /chrome
parent0023337b51004a44391856b64b138ba93a432ec3 (diff)
downloadchromium_src-d75aba1dd9552b603fc713fd00927b28bfd824bf.zip
chromium_src-d75aba1dd9552b603fc713fd00927b28bfd824bf.tar.gz
chromium_src-d75aba1dd9552b603fc713fd00927b28bfd824bf.tar.bz2
Use the blue style for the save password info bar.
BUG=47233 TEST=go to mail.google.com, log in, wait until the info bar appears, see if the info bar has a blue background. Review URL: http://codereview.chromium.org/3080016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@54634 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/tab_contents/tab_contents.cc24
1 files changed, 13 insertions, 11 deletions
diff --git a/chrome/browser/tab_contents/tab_contents.cc b/chrome/browser/tab_contents/tab_contents.cc
index 5ab30a2..18050bf 100644
--- a/chrome/browser/tab_contents/tab_contents.cc
+++ b/chrome/browser/tab_contents/tab_contents.cc
@@ -3186,18 +3186,19 @@ class SavePasswordInfoBarDelegate : public ConfirmInfoBarDelegate {
PasswordFormManager* form_to_save)
: ConfirmInfoBarDelegate(tab_contents),
form_to_save_(form_to_save),
- infobar_response_(kNoResponse) {
- }
+ infobar_response_(NO_RESPONSE) {}
- virtual ~SavePasswordInfoBarDelegate() { }
+ virtual ~SavePasswordInfoBarDelegate() {}
- // Overridden from ConfirmInfoBarDelegate:
+ // Begin ConfirmInfoBarDelegate implementation.
virtual void InfoBarClosed() {
UMA_HISTOGRAM_ENUMERATION("PasswordManager.InfoBarResponse",
- infobar_response_, kNumResponseTypes);
+ infobar_response_, NUM_RESPONSE_TYPES);
delete this;
}
+ virtual Type GetInfoBarType() { return PAGE_ACTION_TYPE; }
+
virtual std::wstring GetMessageText() const {
return l10n_util::GetString(IDS_PASSWORD_MANAGER_SAVE_PASSWORD_PROMPT);
}
@@ -3223,16 +3224,17 @@ class SavePasswordInfoBarDelegate : public ConfirmInfoBarDelegate {
virtual bool Accept() {
DCHECK(form_to_save_.get());
form_to_save_->Save();
- infobar_response_ = kRememberPassword;
+ infobar_response_ = REMEMBER_PASSWORD;
return true;
}
virtual bool Cancel() {
DCHECK(form_to_save_.get());
form_to_save_->PermanentlyBlacklist();
- infobar_response_ = kDontRememberPassword;
+ infobar_response_ = DONT_REMEMBER_PASSWORD;
return true;
}
+ // End ConfirmInfoBarDelegate implementation.
private:
// The PasswordFormManager managing the form we're asking the user about,
@@ -3241,10 +3243,10 @@ class SavePasswordInfoBarDelegate : public ConfirmInfoBarDelegate {
// Used to track the results we get from the info bar.
enum ResponseType {
- kNoResponse = 0,
- kRememberPassword,
- kDontRememberPassword,
- kNumResponseTypes,
+ NO_RESPONSE = 0,
+ REMEMBER_PASSWORD,
+ DONT_REMEMBER_PASSWORD,
+ NUM_RESPONSE_TYPES,
};
ResponseType infobar_response_;