Index: chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc |
diff --git a/chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc b/chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc |
index 939415482b7f1202ea2855f654f255b5652d0f49..bd8c4d744d0520ba4fc375415b3b30cd2289dd7b 100644 |
--- a/chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc |
+++ b/chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc |
@@ -349,6 +349,10 @@ bool TabRendererGtk::is_blocked() const { |
return data_.blocked; |
} |
+bool TabRendererGtk::IsActive() const { |
+ return true; |
+} |
+ |
bool TabRendererGtk::IsSelected() const { |
return true; |
} |
@@ -390,7 +394,7 @@ void TabRendererGtk::PaintFaviconArea(GdkEventExpose* event) { |
// Paint the background behind the favicon. |
int theme_id; |
int offset_y = 0; |
- if (IsSelected()) { |
+ if (IsActive()) { |
theme_id = IDR_THEME_TOOLBAR; |
} else { |
if (!data_.incognito) { |
@@ -407,7 +411,7 @@ void TabRendererGtk::PaintFaviconArea(GdkEventExpose* event) { |
favicon_bounds_.x(), favicon_bounds_.y(), |
favicon_bounds_.width(), favicon_bounds_.height()); |
- if (!IsSelected()) { |
+ if (!IsActive()) { |
double throb_value = GetThrobValue(); |
if (throb_value > 0) { |
SkRect bounds; |
@@ -434,7 +438,7 @@ bool TabRendererGtk::ShouldShowIcon() const { |
return true; |
} else if (!data_.show_icon) { |
return false; |
- } else if (IsSelected()) { |
+ } else if (IsActive()) { |
// The selected tab clips favicon before close button. |
return IconCapacity() >= 2; |
} |
@@ -821,7 +825,7 @@ void TabRendererGtk::PaintTitle(gfx::Canvas* canvas) { |
Browser::FormatTitleForDisplay(&title); |
} |
- SkColor title_color = IsSelected() ? selected_title_color_ |
+ SkColor title_color = IsActive() ? selected_title_color_ |
: unselected_title_color_; |
canvas->DrawStringInt(title, *title_font_, title_color, |
title_bounds_.x(), title_bounds_.y(), |
@@ -878,7 +882,7 @@ void TabRendererGtk::PaintIcon(gfx::Canvas* canvas) { |
} |
void TabRendererGtk::PaintTabBackground(gfx::Canvas* canvas) { |
- if (IsSelected()) { |
+ if (IsActive()) { |
PaintActiveTabBackground(canvas); |
} else { |
PaintInactiveTabBackground(canvas); |
@@ -903,6 +907,8 @@ void TabRendererGtk::PaintInactiveTabBackground(gfx::Canvas* canvas) { |
int tab_id = data_.incognito ? |
IDR_THEME_TAB_BACKGROUND_INCOGNITO : IDR_THEME_TAB_BACKGROUND; |
+ if (IsSelected()) |
+ tab_id = IDR_THEME_TAB_BACKGROUND_V; |
James Hawkins
2011/05/12 21:59:52
Does this also work for incognito windows?
dpapad
2011/05/12 22:31:38
It seems to me that a new theme should be added fo
|
SkBitmap* tab_bg = theme_service_->GetBitmapNamed(tab_id); |
@@ -991,7 +997,7 @@ int TabRendererGtk::IconCapacity() const { |
bool TabRendererGtk::ShouldShowCloseBox() const { |
// The selected tab never clips close button. |
- return !mini() && (IsSelected() || IconCapacity() >= 3); |
+ return !mini() && (IsActive() || IconCapacity() >= 3); |
} |
CustomDrawButton* TabRendererGtk::MakeCloseButton() { |