summaryrefslogtreecommitdiffstats
path: root/chrome/browser/gtk
diff options
context:
space:
mode:
authorpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-23 20:54:48 +0000
committerpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-23 20:54:48 +0000
commit96c2e8ec18feb0766c22acfb481a59f0983c572a (patch)
tree3b1d3f8312d8bdb9bc789bf9859298368021b681 /chrome/browser/gtk
parent9520ab113d86539f1deba7d107776f0b8ee72a12 (diff)
downloadchromium_src-96c2e8ec18feb0766c22acfb481a59f0983c572a.zip
chromium_src-96c2e8ec18feb0766c22acfb481a59f0983c572a.tar.gz
chromium_src-96c2e8ec18feb0766c22acfb481a59f0983c572a.tar.bz2
Reverting 26975.
Review URL: http://codereview.chromium.org/222011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26979 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk')
-rw-r--r--chrome/browser/gtk/browser_titlebar.cc4
-rw-r--r--chrome/browser/gtk/browser_window_gtk.cc6
-rw-r--r--chrome/browser/gtk/custom_button.cc6
-rw-r--r--chrome/browser/gtk/gtk_theme_provider.cc4
-rw-r--r--chrome/browser/gtk/gtk_theme_provider.h5
-rw-r--r--chrome/browser/gtk/tabs/tab_renderer_gtk.cc6
6 files changed, 16 insertions, 15 deletions
diff --git a/chrome/browser/gtk/browser_titlebar.cc b/chrome/browser/gtk/browser_titlebar.cc
index 9405c70..cc72cf6 100644
--- a/chrome/browser/gtk/browser_titlebar.cc
+++ b/chrome/browser/gtk/browser_titlebar.cc
@@ -10,7 +10,6 @@
#include <string>
#include <vector>
-#include "app/gfx/skbitmap_operations.h"
#include "app/l10n_util.h"
#include "app/resource_bundle.h"
#include "base/gfx/gtk_util.h"
@@ -32,6 +31,7 @@
#include "grit/app_resources.h"
#include "grit/generated_resources.h"
#include "grit/theme_resources.h"
+#include "skia/ext/image_operations.h"
namespace {
@@ -590,7 +590,7 @@ static void MakeThrobberFrames(int resource_id,
// Make a separate GdkPixbuf for each frame of the animation.
for (size_t i = 0; i < num_frames; ++i) {
- SkBitmap frame = SkBitmapOperations::CreateTiledBitmap(*frame_strip,
+ SkBitmap frame = skia::ImageOperations::CreateTiledBitmap(*frame_strip,
i * frame_size, 0, frame_size, frame_size);
frames->push_back(gfx::GdkPixbufFromSkBitmap(&frame));
}
diff --git a/chrome/browser/gtk/browser_window_gtk.cc b/chrome/browser/gtk/browser_window_gtk.cc
index bc4ba6f..aec56c2 100644
--- a/chrome/browser/gtk/browser_window_gtk.cc
+++ b/chrome/browser/gtk/browser_window_gtk.cc
@@ -9,7 +9,6 @@
#include <string>
-#include "app/gfx/color_utils.h"
#include "app/l10n_util.h"
#include "app/resource_bundle.h"
#include "app/theme_provider.h"
@@ -76,6 +75,7 @@
#include "grit/generated_resources.h"
#include "grit/google_chrome_strings.h"
#include "grit/theme_resources.h"
+#include "skia/ext/skia_utils.h"
#include "skia/ext/skia_utils_gtk.h"
#if defined(OS_CHROMEOS)
@@ -1765,8 +1765,8 @@ void BrowserWindowGtk::SetBackgroundColor() {
// When the cursor is over the divider, GTK+ normally lightens the background
// color by 1.3 (see LIGHTNESS_MULT in gtkstyle.c). Since we're setting the
// color, override the prelight also.
- color_utils::HSL hsl = { -1, 0.5, 0.65 };
- SkColor frame_prelight_color = color_utils::HSLShift(frame_color, hsl);
+ skia::HSL hsl = { -1, 0.5, 0.65 };
+ SkColor frame_prelight_color = skia::HSLShift(frame_color, hsl);
GdkColor frame_prelight_color_gdk = SkColorToGdkColor(frame_prelight_color);
gtk_widget_modify_bg(contents_split_, GTK_STATE_PRELIGHT,
&frame_prelight_color_gdk);
diff --git a/chrome/browser/gtk/custom_button.cc b/chrome/browser/gtk/custom_button.cc
index 3e4e1cf..745f495 100644
--- a/chrome/browser/gtk/custom_button.cc
+++ b/chrome/browser/gtk/custom_button.cc
@@ -4,7 +4,6 @@
#include "chrome/browser/gtk/custom_button.h"
-#include "app/gfx/skbitmap_operations.h"
#include "app/l10n_util.h"
#include "app/resource_bundle.h"
#include "app/theme_provider.h"
@@ -16,6 +15,7 @@
#include "chrome/common/gtk_util.h"
#include "chrome/common/notification_service.h"
#include "grit/theme_resources.h"
+#include "skia/ext/image_operations.h"
CustomDrawButtonBase::CustomDrawButtonBase(GtkThemeProvider* theme_provider,
int normal_id, int active_id, int highlight_id, int depressed_id)
@@ -104,8 +104,8 @@ void CustomDrawButtonBase::SetBackground(SkColor color,
background_image_->UsePixbuf(NULL);
}
} else {
- SkBitmap img =
- SkBitmapOperations::CreateButtonBackground(color, *image, *mask);
+ SkBitmap img = skia::ImageOperations::CreateButtonBackground(color,
+ *image, *mask);
GdkPixbuf* pixbuf = gfx::GdkPixbufFromSkBitmap(&img);
background_image_->UsePixbuf(pixbuf);
diff --git a/chrome/browser/gtk/gtk_theme_provider.cc b/chrome/browser/gtk/gtk_theme_provider.cc
index 2354d1d..428e58b 100644
--- a/chrome/browser/gtk/gtk_theme_provider.cc
+++ b/chrome/browser/gtk/gtk_theme_provider.cc
@@ -352,8 +352,8 @@ void GtkThemeProvider::LoadGtkValues() {
// color, change the luminosity of the frame color downwards to 80% of what
// it currently is. This is in a futile attempt to match the default
// metacity and xfwm themes.
- SkColor shifted = color_utils::HSLShift(GdkToSkColor(&frame_color),
- kDefaultFrameShift);
+ SkColor shifted = skia::HSLShift(GdkToSkColor(&frame_color),
+ kDefaultFrameShift);
frame_color.pixel = 0;
frame_color.red = SkColorGetR(shifted) * kSkiaToGDKMultiplier;
frame_color.green = SkColorGetG(shifted) * kSkiaToGDKMultiplier;
diff --git a/chrome/browser/gtk/gtk_theme_provider.h b/chrome/browser/gtk/gtk_theme_provider.h
index a7b7ab3..14b6e73 100644
--- a/chrome/browser/gtk/gtk_theme_provider.h
+++ b/chrome/browser/gtk/gtk_theme_provider.h
@@ -9,11 +9,12 @@
#include <string>
#include <vector>
-#include "app/gfx/color_utils.h"
#include "chrome/browser/browser_theme_provider.h"
#include "chrome/common/notification_observer.h"
#include "chrome/common/owned_widget_gtk.h"
+#include "skia/ext/skia_utils.h"
+
class CairoCachedSurface;
class Profile;
@@ -111,7 +112,7 @@ class GtkThemeProvider : public BrowserThemeProvider,
// Sets the underlying theme colors/tints from a GTK color.
void SetThemeColorFromGtk(const char* id, GdkColor* color);
void SetThemeTintFromGtk(const char* id, GdkColor* color,
- const color_utils::HSL& default_tint);
+ const skia::HSL& default_tint);
// Split out from FreePlatformCaches so it can be called in our destructor;
// FreePlatformCaches() is called from the BrowserThemeProvider's destructor,
diff --git a/chrome/browser/gtk/tabs/tab_renderer_gtk.cc b/chrome/browser/gtk/tabs/tab_renderer_gtk.cc
index 658d01f..213475a 100644
--- a/chrome/browser/gtk/tabs/tab_renderer_gtk.cc
+++ b/chrome/browser/gtk/tabs/tab_renderer_gtk.cc
@@ -9,7 +9,6 @@
#include "app/gfx/canvas_paint.h"
#include "app/gfx/favicon_size.h"
-#include "app/gfx/skbitmap_operations.h"
#include "app/l10n_util.h"
#include "app/resource_bundle.h"
#include "chrome/browser/browser.h"
@@ -24,6 +23,7 @@
#include "grit/app_resources.h"
#include "grit/generated_resources.h"
#include "grit/theme_resources.h"
+#include "skia/ext/image_operations.h"
namespace {
@@ -697,13 +697,13 @@ SkBitmap* TabRendererGtk::GetMaskedBitmap(const SkBitmap* mask,
// offsets.
delete it->second.bitmap;
}
- SkBitmap image = SkBitmapOperations::CreateTiledBitmap(
+ SkBitmap image = skia::ImageOperations::CreateTiledBitmap(
*background, bg_offset_x, bg_offset_y, mask->width(),
height() + kToolbarOverlap);
CachedBitmap bitmap = {
bg_offset_x,
bg_offset_y,
- new SkBitmap(SkBitmapOperations::CreateMaskedBitmap(image, *mask))
+ new SkBitmap(skia::ImageOperations::CreateMaskedBitmap(image, *mask))
};
cached_bitmaps_[std::make_pair(mask, background)] = bitmap;
return bitmap.bitmap;