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

Unified Diff: chrome/browser/tab_contents/infobar_delegate.cc

Issue 5741001: Even more virtual method deinlining. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase (windows) Created 10 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
« no previous file with comments | « chrome/browser/tab_contents/infobar_delegate.h ('k') | chrome/browser/themes/browser_theme_provider.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/tab_contents/infobar_delegate.cc
diff --git a/chrome/browser/tab_contents/infobar_delegate.cc b/chrome/browser/tab_contents/infobar_delegate.cc
index aae8553b1612ed73840787d1064054adc6064936..671d17bd467143569bcc5ac10ee3456e1a0a0ee6 100644
--- a/chrome/browser/tab_contents/infobar_delegate.cc
+++ b/chrome/browser/tab_contents/infobar_delegate.cc
@@ -14,6 +14,10 @@
// InfoBarDelegate: ------------------------------------------------------------
+bool InfoBarDelegate::EqualsDelegate(InfoBarDelegate* delegate) const {
+ return false;
+}
+
bool InfoBarDelegate::ShouldExpire(
const NavigationController::LoadCommittedDetails& details) const {
bool is_reload =
@@ -22,6 +26,44 @@ bool InfoBarDelegate::ShouldExpire(
return is_reload || (contents_unique_id_ != details.entry->unique_id());
}
+SkBitmap* InfoBarDelegate::GetIcon() const {
+ return NULL;
+}
+
+AlertInfoBarDelegate* InfoBarDelegate::AsAlertInfoBarDelegate() {
+ return NULL;
+}
+
+LinkInfoBarDelegate* InfoBarDelegate::AsLinkInfoBarDelegate() {
+ return NULL;
+}
+
+ConfirmInfoBarDelegate* InfoBarDelegate::AsConfirmInfoBarDelegate() {
+ return NULL;
+}
+
+ThemeInstalledInfoBarDelegate*
+InfoBarDelegate::AsThemePreviewInfobarDelegate() {
+ return NULL;
+}
+
+TranslateInfoBarDelegate* InfoBarDelegate::AsTranslateInfoBarDelegate() {
+ return NULL;
+}
+
+ExtensionInfoBarDelegate* InfoBarDelegate::AsExtensionInfoBarDelegate() {
+ return NULL;
+}
+
+CrashedExtensionInfoBarDelegate*
+InfoBarDelegate::AsCrashedExtensionInfoBarDelegate() {
+ return NULL;
+}
+
+InfoBarDelegate::Type InfoBarDelegate::GetInfoBarType() {
+ return WARNING_TYPE;
+}
+
InfoBarDelegate::InfoBarDelegate(TabContents* contents)
: contents_unique_id_(0) {
if (contents)
@@ -35,6 +77,10 @@ void InfoBarDelegate::StoreActiveEntryUniqueID(TabContents* contents) {
// AlertInfoBarDelegate: -------------------------------------------------------
+SkBitmap* AlertInfoBarDelegate::GetIcon() const {
+ return NULL;
+}
+
bool AlertInfoBarDelegate::EqualsDelegate(InfoBarDelegate* delegate) const {
AlertInfoBarDelegate* alert_delegate = delegate->AsAlertInfoBarDelegate();
if (!alert_delegate)
@@ -43,18 +89,44 @@ bool AlertInfoBarDelegate::EqualsDelegate(InfoBarDelegate* delegate) const {
return alert_delegate->GetMessageText() == GetMessageText();
}
+AlertInfoBarDelegate* AlertInfoBarDelegate::AsAlertInfoBarDelegate() {
+ return this;
+}
+
AlertInfoBarDelegate::AlertInfoBarDelegate(TabContents* contents)
: InfoBarDelegate(contents) {
}
// LinkInfoBarDelegate: --------------------------------------------------------
+string16 LinkInfoBarDelegate::GetMessageTextWithOffset(
+ size_t* link_offset) const {
+ *link_offset = string16::npos;
+ return string16();
+}
+
+SkBitmap* LinkInfoBarDelegate::GetIcon() const {
+ return NULL;
+}
+
+bool LinkInfoBarDelegate::LinkClicked(WindowOpenDisposition disposition) {
+ return true;
+}
+
+LinkInfoBarDelegate* LinkInfoBarDelegate::AsLinkInfoBarDelegate() {
+ return this;
+}
+
LinkInfoBarDelegate::LinkInfoBarDelegate(TabContents* contents)
: InfoBarDelegate(contents) {
}
// ConfirmInfoBarDelegate: -----------------------------------------------------
+int ConfirmInfoBarDelegate::GetButtons() const {
+ return BUTTON_NONE;
+}
+
string16 ConfirmInfoBarDelegate::GetButtonLabel(
InfoBarButton button) const {
if (button == BUTTON_OK)
@@ -65,6 +137,30 @@ string16 ConfirmInfoBarDelegate::GetButtonLabel(
return string16();
}
+bool ConfirmInfoBarDelegate::NeedElevation(InfoBarButton button) const {
+ return false;
+}
+
+bool ConfirmInfoBarDelegate::Accept() {
+ return true;
+}
+
+bool ConfirmInfoBarDelegate::Cancel() {
+ return true;
+}
+
+string16 ConfirmInfoBarDelegate::GetLinkText() {
+ return string16();
+}
+
+bool ConfirmInfoBarDelegate::LinkClicked(WindowOpenDisposition disposition) {
+ return true;
+}
+
+ConfirmInfoBarDelegate* ConfirmInfoBarDelegate::AsConfirmInfoBarDelegate() {
+ return this;
+}
+
ConfirmInfoBarDelegate::ConfirmInfoBarDelegate(TabContents* contents)
: AlertInfoBarDelegate(contents) {
}
« no previous file with comments | « chrome/browser/tab_contents/infobar_delegate.h ('k') | chrome/browser/themes/browser_theme_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698