OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/infobars/insecure_content_infobar_delegate.h" | 5 #include "chrome/browser/infobars/insecure_content_infobar_delegate.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 infobar_service->AddInfoBar(std::move(new_infobar)); | 44 infobar_service->AddInfoBar(std::move(new_infobar)); |
45 } | 45 } |
46 | 46 |
47 InsecureContentInfoBarDelegate::InsecureContentInfoBarDelegate() | 47 InsecureContentInfoBarDelegate::InsecureContentInfoBarDelegate() |
48 : ConfirmInfoBarDelegate() { | 48 : ConfirmInfoBarDelegate() { |
49 } | 49 } |
50 | 50 |
51 InsecureContentInfoBarDelegate::~InsecureContentInfoBarDelegate() { | 51 InsecureContentInfoBarDelegate::~InsecureContentInfoBarDelegate() { |
52 } | 52 } |
53 | 53 |
| 54 infobars::InfoBarDelegate::InfoBarIdentifier |
| 55 InsecureContentInfoBarDelegate::GetIdentifier() const { |
| 56 return INSECURE_CONTENT_INFOBAR_DELEGATE; |
| 57 } |
| 58 |
54 void InsecureContentInfoBarDelegate::InfoBarDismissed() { | 59 void InsecureContentInfoBarDelegate::InfoBarDismissed() { |
55 UMA_HISTOGRAM_ENUMERATION("InsecureContentInfoBarDelegateV2", | 60 UMA_HISTOGRAM_ENUMERATION("InsecureContentInfoBarDelegateV2", |
56 DISPLAY_INFOBAR_DISMISSED, NUM_EVENTS); | 61 DISPLAY_INFOBAR_DISMISSED, NUM_EVENTS); |
57 ConfirmInfoBarDelegate::InfoBarDismissed(); | 62 ConfirmInfoBarDelegate::InfoBarDismissed(); |
58 } | 63 } |
59 | 64 |
60 InsecureContentInfoBarDelegate* | 65 InsecureContentInfoBarDelegate* |
61 InsecureContentInfoBarDelegate::AsInsecureContentInfoBarDelegate() { | 66 InsecureContentInfoBarDelegate::AsInsecureContentInfoBarDelegate() { |
62 return this; | 67 return this; |
63 } | 68 } |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 return true; | 101 return true; |
97 } | 102 } |
98 | 103 |
99 base::string16 InsecureContentInfoBarDelegate::GetLinkText() const { | 104 base::string16 InsecureContentInfoBarDelegate::GetLinkText() const { |
100 return l10n_util::GetStringUTF16(IDS_LEARN_MORE); | 105 return l10n_util::GetStringUTF16(IDS_LEARN_MORE); |
101 } | 106 } |
102 | 107 |
103 GURL InsecureContentInfoBarDelegate::GetLinkURL() const { | 108 GURL InsecureContentInfoBarDelegate::GetLinkURL() const { |
104 return GURL("https://support.google.com/chrome/answer/1342714"); | 109 return GURL("https://support.google.com/chrome/answer/1342714"); |
105 } | 110 } |
OLD | NEW |