summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-30 02:22:35 +0000
committertfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-30 02:22:35 +0000
commit8db2b8493a35e2318bd47a6be52df88079d0a976 (patch)
tree723ba228d15c286f08ab63b4b719bf6d213e5bc9
parentdae22c5cddc8f1ebdfe77e66ebbf834255f94319 (diff)
downloadchromium_src-8db2b8493a35e2318bd47a6be52df88079d0a976.zip
chromium_src-8db2b8493a35e2318bd47a6be52df88079d0a976.tar.gz
chromium_src-8db2b8493a35e2318bd47a6be52df88079d0a976.tar.bz2
Reland r53603 - Make the OmniboxSearchHint infobar use PAGE_ACTION_TYPE.
This reverts commit 893e3e083fe8d77949860cdb1af7fc14a371651e. It was reverted due to a LINK failure, but reverting didn't fixed either, so I'm relanding it again. BUG=39102 TEST=trybots Review URL: http://codereview.chromium.org/2805096/ TBR=mirandac@chromium.org Review URL: http://codereview.chromium.org/3057018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@54259 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/app/generated_resources.grd3
-rw-r--r--chrome/browser/gtk/infobar_gtk.cc10
-rw-r--r--chrome/browser/omnibox_search_hint.cc4
-rw-r--r--chrome/browser/tab_contents/infobar_delegate.h1
-rw-r--r--chrome/browser/views/infobars/infobars.cc10
5 files changed, 1 insertions, 27 deletions
diff --git a/chrome/app/generated_resources.grd b/chrome/app/generated_resources.grd
index 9ddd479..caf5e10 100644
--- a/chrome/app/generated_resources.grd
+++ b/chrome/app/generated_resources.grd
@@ -3519,9 +3519,6 @@ each locale. -->
<message name="IDS_ACCNAME_INFOBAR_CONTAINER" desc="The accessible name for the infobar container.">
Infobar Container
</message>
- <message name="IDS_ACCNAME_INFOBAR_INFO" desc="The accessible name for the info infobar type.">
- Info
- </message>
<message name="IDS_ACCNAME_INFOBAR_WARNING" desc="The accessible name for the warning infobar type.">
Warning
</message>
diff --git a/chrome/browser/gtk/infobar_gtk.cc b/chrome/browser/gtk/infobar_gtk.cc
index a389853..e06da07 100644
--- a/chrome/browser/gtk/infobar_gtk.cc
+++ b/chrome/browser/gtk/infobar_gtk.cc
@@ -214,11 +214,6 @@ void InfoBar::GetTopColor(InfoBarDelegate::Type type,
// browser/views/infobars/infobars.cc, and then changed into 0-1 ranged
// values for cairo.
switch (type) {
- case InfoBarDelegate::INFO_TYPE:
- *r = 170.0 / 255.0;
- *g = 214.0 / 255.0;
- *b = 112.0 / 255.0;
- break;
case InfoBarDelegate::WARNING_TYPE:
case InfoBarDelegate::ERROR_TYPE:
*r = 255.0 / 255.0;
@@ -236,11 +231,6 @@ void InfoBar::GetTopColor(InfoBarDelegate::Type type,
void InfoBar::GetBottomColor(InfoBarDelegate::Type type,
double* r, double* g, double *b) {
switch (type) {
- case InfoBarDelegate::INFO_TYPE:
- *r = 146.0 / 255.0;
- *g = 205.0 / 255.0;
- *b = 114.0 / 255.0;
- break;
case InfoBarDelegate::WARNING_TYPE:
case InfoBarDelegate::ERROR_TYPE:
*r = 250.0 / 255.0;
diff --git a/chrome/browser/omnibox_search_hint.cc b/chrome/browser/omnibox_search_hint.cc
index c995294..d0ac268 100644
--- a/chrome/browser/omnibox_search_hint.cc
+++ b/chrome/browser/omnibox_search_hint.cc
@@ -87,9 +87,7 @@ class HintInfoBar : public ConfirmInfoBarDelegate {
return l10n_util::GetString(IDS_OMNIBOX_SEARCH_HINT_INFOBAR_BUTTON_LABEL);
}
- virtual Type GetInfoBarType() {
- return INFO_TYPE;
- }
+ virtual Type GetInfoBarType() { return PAGE_ACTION_TYPE; }
virtual bool Accept() {
action_taken_ = true;
diff --git a/chrome/browser/tab_contents/infobar_delegate.h b/chrome/browser/tab_contents/infobar_delegate.h
index c070161..7be7b1e 100644
--- a/chrome/browser/tab_contents/infobar_delegate.h
+++ b/chrome/browser/tab_contents/infobar_delegate.h
@@ -49,7 +49,6 @@ class InfoBarDelegate {
// The type of the infobar. It controls its appearance, such as its background
// color.
enum Type {
- INFO_TYPE,
WARNING_TYPE,
ERROR_TYPE,
PAGE_ACTION_TYPE
diff --git a/chrome/browser/views/infobars/infobars.cc b/chrome/browser/views/infobars/infobars.cc
index b36e183..1d78058 100644
--- a/chrome/browser/views/infobars/infobars.cc
+++ b/chrome/browser/views/infobars/infobars.cc
@@ -57,14 +57,7 @@ InfoBarBackground::InfoBarBackground(InfoBarDelegate::Type infobar_type) {
SkColor top_color;
SkColor bottom_color;
switch (infobar_type) {
- case InfoBarDelegate::INFO_TYPE:
- top_color = kInfoBackgroundColorTop;
- bottom_color = kInfoBackgroundColorBottom;
- break;
case InfoBarDelegate::WARNING_TYPE:
- top_color = kWarningBackgroundColorTop;
- bottom_color = kWarningBackgroundColorBottom;
- break;
case InfoBarDelegate::ERROR_TYPE:
top_color = kErrorBackgroundColorTop;
bottom_color = kErrorBackgroundColorBottom;
@@ -108,9 +101,6 @@ InfoBar::InfoBar(InfoBarDelegate* delegate)
set_background(new InfoBarBackground(delegate->GetInfoBarType()));
switch (delegate->GetInfoBarType()) {
- case InfoBarDelegate::INFO_TYPE:
- SetAccessibleName(l10n_util::GetString(IDS_ACCNAME_INFOBAR_INFO));
- break;
case InfoBarDelegate::WARNING_TYPE:
SetAccessibleName(l10n_util::GetString(IDS_ACCNAME_INFOBAR_WARNING));
break;