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

Unified Diff: components/infobars/core/confirm_infobar_delegate.h

Issue 1361253002: Separate the URL of an infobar link with clicking on it. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fit Created 5 years, 3 months 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: components/infobars/core/confirm_infobar_delegate.h
diff --git a/components/infobars/core/confirm_infobar_delegate.h b/components/infobars/core/confirm_infobar_delegate.h
index d36ea224a272009f16eb86c784a12442358af7fc..479bab7ac5aa6dfce795ae260fa0ade2cfe037a3 100644
--- a/components/infobars/core/confirm_infobar_delegate.h
+++ b/components/infobars/core/confirm_infobar_delegate.h
@@ -9,6 +9,7 @@
#include "base/strings/string16.h"
#include "components/infobars/core/infobar_delegate.h"
#include "components/infobars/core/infobar_manager.h"
+#include "url/gurl.h"
namespace infobars {
class InfoBar;
@@ -55,10 +56,13 @@ class ConfirmInfoBarDelegate : public infobars::InfoBarDelegate {
virtual bool Cancel();
// Returns the text of the link to be displayed, if any. Otherwise returns
- // and empty string.
+ // an empty string.
virtual base::string16 GetLinkText() const;
- // Called when the Link (if any) is clicked. The |disposition| specifies how
+ // Returns the URL of the link to be displayed.
+ virtual GURL GetLinkURL() const;
+
+ // Called when the link (if any) is clicked. The |disposition| specifies how
// the resulting document should be loaded (based on the event flags present
// when the link was clicked). If this function returns true, the infobar is
// then immediately closed. Subclasses MUST NOT return true if in handling

Powered by Google App Engine
This is Rietveld 408576698