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

Side by Side Diff: chrome/browser/password_manager/password_manager_infobar_delegate.cc

Issue 1467993002: Remove ManagePasswordsUIController::NavigateToSmartLockPage (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Switching infobars to non-localised link, moving kPasswordManagerAccountDashboardURL to components Created 5 years, 1 month 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 #include "chrome/browser/password_manager/password_manager_infobar_delegate.h" 5 #include "chrome/browser/password_manager/password_manager_infobar_delegate.h"
6 6
7 #include "chrome/browser/infobars/infobar_service.h" 7 #include "chrome/browser/infobars/infobar_service.h"
8 #include "chrome/grit/chromium_strings.h"
9 #include "chrome/grit/generated_resources.h"
10 #include "components/infobars/core/infobar.h" 8 #include "components/infobars/core/infobar.h"
9 #include "components/password_manager/core/browser/password_manager_constants.h"
11 #include "content/public/browser/web_contents.h" 10 #include "content/public/browser/web_contents.h"
12 #include "grit/theme_resources.h" 11 #include "grit/theme_resources.h"
13 #include "ui/base/l10n/l10n_util.h"
14 12
15 PasswordManagerInfoBarDelegate::~PasswordManagerInfoBarDelegate() {} 13 PasswordManagerInfoBarDelegate::~PasswordManagerInfoBarDelegate() {}
16 14
17 PasswordManagerInfoBarDelegate::PasswordManagerInfoBarDelegate() 15 PasswordManagerInfoBarDelegate::PasswordManagerInfoBarDelegate()
18 : ConfirmInfoBarDelegate(), message_link_range_(gfx::Range()) {} 16 : ConfirmInfoBarDelegate(), message_link_range_(gfx::Range()) {}
19 17
20 infobars::InfoBarDelegate::Type PasswordManagerInfoBarDelegate::GetInfoBarType() 18 infobars::InfoBarDelegate::Type PasswordManagerInfoBarDelegate::GetInfoBarType()
21 const { 19 const {
22 return PAGE_ACTION_TYPE; 20 return PAGE_ACTION_TYPE;
23 } 21 }
(...skipping 10 matching lines...) Expand all
34 bool PasswordManagerInfoBarDelegate::ShouldExpire( 32 bool PasswordManagerInfoBarDelegate::ShouldExpire(
35 const NavigationDetails& details) const { 33 const NavigationDetails& details) const {
36 return !details.is_redirect && ConfirmInfoBarDelegate::ShouldExpire(details); 34 return !details.is_redirect && ConfirmInfoBarDelegate::ShouldExpire(details);
37 } 35 }
38 36
39 base::string16 PasswordManagerInfoBarDelegate::GetMessageText() const { 37 base::string16 PasswordManagerInfoBarDelegate::GetMessageText() const {
40 return message_; 38 return message_;
41 } 39 }
42 40
43 GURL PasswordManagerInfoBarDelegate::GetLinkURL() const { 41 GURL PasswordManagerInfoBarDelegate::GetLinkURL() const {
44 return GURL(l10n_util::GetStringUTF16(IDS_PASSWORD_MANAGER_SMART_LOCK_PAGE)); 42 return GURL(password_manager::kPasswordManagerAccountDashboardURL);
45 } 43 }
46 44
47 bool PasswordManagerInfoBarDelegate::LinkClicked( 45 bool PasswordManagerInfoBarDelegate::LinkClicked(
48 WindowOpenDisposition disposition) { 46 WindowOpenDisposition disposition) {
49 ConfirmInfoBarDelegate::LinkClicked(disposition); 47 ConfirmInfoBarDelegate::LinkClicked(disposition);
50 return true; 48 return true;
51 } 49 }
52 50
53 void PasswordManagerInfoBarDelegate::SetMessage(const base::string16& message) { 51 void PasswordManagerInfoBarDelegate::SetMessage(const base::string16& message) {
54 message_ = message; 52 message_ = message;
55 } 53 }
56 54
57 void PasswordManagerInfoBarDelegate::SetMessageLinkRange( 55 void PasswordManagerInfoBarDelegate::SetMessageLinkRange(
58 const gfx::Range& message_link_range) { 56 const gfx::Range& message_link_range) {
59 message_link_range_ = message_link_range; 57 message_link_range_ = message_link_range;
60 } 58 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698