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

Unified Diff: chrome/browser/devtools/global_confirm_info_bar.cc

Issue 1520543004: Add method for identifying different InfoBars (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebasing Created 5 years 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/devtools/global_confirm_info_bar.cc
diff --git a/chrome/browser/devtools/global_confirm_info_bar.cc b/chrome/browser/devtools/global_confirm_info_bar.cc
index 0fd261e81a795938551cff0a515434767e558123..f8e81675f04ed811deff1cc316b0644e3029f0ad 100644
--- a/chrome/browser/devtools/global_confirm_info_bar.cc
+++ b/chrome/browser/devtools/global_confirm_info_bar.cc
@@ -22,6 +22,7 @@ class GlobalConfirmInfoBar::DelegateProxy : public ConfirmInfoBarDelegate {
friend class GlobalConfirmInfoBar;
// ConfirmInfoBarDelegate overrides
+ std::string GetIdentifier() const override;
base::string16 GetMessageText() const override;
int GetButtons() const override;
base::string16 GetButtonLabel(InfoBarButton button) const override;
@@ -48,6 +49,11 @@ GlobalConfirmInfoBar::DelegateProxy::DelegateProxy(
GlobalConfirmInfoBar::DelegateProxy::~DelegateProxy() {
}
+std::string GlobalConfirmInfoBar::DelegateProxy::GetIdentifier() const {
+ return global_info_bar_ ? global_info_bar_->delegate_->GetIdentifier()
+ : "GlobalConfirmInfoBar";
+}
+
base::string16 GlobalConfirmInfoBar::DelegateProxy::GetMessageText() const {
return global_info_bar_ ? global_info_bar_->delegate_->GetMessageText()
: base::string16();

Powered by Google App Engine
This is Rietveld 408576698