summaryrefslogtreecommitdiffstats
path: root/chrome/browser
diff options
context:
space:
mode:
authorbeng@google.com <beng@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-14 23:16:21 +0000
committerbeng@google.com <beng@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-14 23:16:21 +0000
commite5a99ff3bd91f5493e7916b9dca6b29429ce0f43 (patch)
treecc12f65483a8c95dcea331605cc84af3a7c18da6 /chrome/browser
parent63e9985f427227c977c96d1105de6e251dfd7554 (diff)
downloadchromium_src-e5a99ff3bd91f5493e7916b9dca6b29429ce0f43.zip
chromium_src-e5a99ff3bd91f5493e7916b9dca6b29429ce0f43.tar.gz
chromium_src-e5a99ff3bd91f5493e7916b9dca6b29429ce0f43.tar.bz2
Move bitmap conversion function from chrome/common/gtk_utils.h into app/gfx/gtk_utils.h
http://crbug.com/11387 Review URL: http://codereview.chromium.org/115382 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16122 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser')
-rw-r--r--chrome/browser/bookmarks/bookmark_menu_controller_gtk.cc1
-rw-r--r--chrome/browser/gtk/bookmark_bar_gtk.cc5
-rw-r--r--chrome/browser/gtk/find_bar_gtk.cc14
-rw-r--r--chrome/browser/gtk/hung_renderer_dialog_gtk.cc2
-rw-r--r--chrome/browser/gtk/infobar_container_gtk.cc2
-rw-r--r--chrome/browser/gtk/infobar_gtk.cc5
-rw-r--r--chrome/browser/gtk/menu_gtk.cc2
7 files changed, 17 insertions, 14 deletions
diff --git a/chrome/browser/bookmarks/bookmark_menu_controller_gtk.cc b/chrome/browser/bookmarks/bookmark_menu_controller_gtk.cc
index 6787338..033bc8ee 100644
--- a/chrome/browser/bookmarks/bookmark_menu_controller_gtk.cc
+++ b/chrome/browser/bookmarks/bookmark_menu_controller_gtk.cc
@@ -6,6 +6,7 @@
#include <gtk/gtk.h>
+#include "app/gfx/gtk_util.h"
#include "app/l10n_util.h"
#include "app/resource_bundle.h"
#include "base/string_util.h"
diff --git a/chrome/browser/gtk/bookmark_bar_gtk.cc b/chrome/browser/gtk/bookmark_bar_gtk.cc
index ebfe567..649c2c64 100644
--- a/chrome/browser/gtk/bookmark_bar_gtk.cc
+++ b/chrome/browser/gtk/bookmark_bar_gtk.cc
@@ -4,6 +4,7 @@
#include "chrome/browser/gtk/bookmark_bar_gtk.h"
+#include "app/gfx/gtk_util.h"
#include "app/gfx/text_elider.h"
#include "app/l10n_util.h"
#include "app/resource_bundle.h"
@@ -95,7 +96,7 @@ void BookmarkBarGtk::Init(Profile* profile) {
static GdkPixbuf* folder_icon = rb.GetPixbufNamed(IDR_BOOKMARK_BAR_FOLDER);
bookmark_hbox_ = gtk_hbox_new(FALSE, 0);
- container_.Own(gfx::CreateGtkBorderBin(bookmark_hbox_, &kBackgroundColor,
+ container_.Own(gtk_util::CreateGtkBorderBin(bookmark_hbox_, &kBackgroundColor,
kBarPadding, kBarPadding, kBarPadding, kBarPadding));
instructions_ =
@@ -273,7 +274,7 @@ void BookmarkBarGtk::SetInstructionState(BookmarkNode* boomarks_bar_node) {
}
void BookmarkBarGtk::RemoveAllBookmarkButtons() {
- gfx::RemoveAllChildren(bookmark_toolbar_.get());
+ gtk_util::RemoveAllChildren(bookmark_toolbar_.get());
}
int BookmarkBarGtk::GetBookmarkButtonCount() {
diff --git a/chrome/browser/gtk/find_bar_gtk.cc b/chrome/browser/gtk/find_bar_gtk.cc
index 30720d2..2a2c27d 100644
--- a/chrome/browser/gtk/find_bar_gtk.cc
+++ b/chrome/browser/gtk/find_bar_gtk.cc
@@ -99,7 +99,7 @@ void FindBarGtk::InitWidgets() {
// lateral position. We put that fixed in a SlideAnimatorGtk in order to get
// the slide effect.
GtkWidget* hbox = gtk_hbox_new(false, 0);
- container_ = gfx::CreateGtkBorderBin(hbox, NULL,
+ container_ = gtk_util::CreateGtkBorderBin(hbox, NULL,
kBarPaddingTopBottom, kBarPaddingTopBottom,
kEntryPaddingLeft, kBarPaddingRight);
gtk_widget_set_app_paintable(container_, TRUE);
@@ -162,12 +162,12 @@ void FindBarGtk::InitWidgets() {
gtk_box_pack_end(GTK_BOX(content_hbox), text_entry_, TRUE, TRUE, 0);
// We fake anti-aliasing by having two borders.
- GtkWidget* border_bin = gfx::CreateGtkBorderBin(content_hbox,
- &kTextBorderColor,
- 1, 1, 1, 0);
- GtkWidget* border_bin_aa = gfx::CreateGtkBorderBin(border_bin,
- &kTextBorderColorAA,
- 1, 1, 1, 0);
+ GtkWidget* border_bin = gtk_util::CreateGtkBorderBin(content_hbox,
+ &kTextBorderColor,
+ 1, 1, 1, 0);
+ GtkWidget* border_bin_aa = gtk_util::CreateGtkBorderBin(border_bin,
+ &kTextBorderColorAA,
+ 1, 1, 1, 0);
GtkWidget* centering_vbox = gtk_vbox_new(FALSE, 0);
gtk_box_pack_start(GTK_BOX(centering_vbox), border_bin_aa, TRUE, FALSE, 0);
gtk_box_pack_end(GTK_BOX(hbox), centering_vbox, FALSE, FALSE, 0);
diff --git a/chrome/browser/gtk/hung_renderer_dialog_gtk.cc b/chrome/browser/gtk/hung_renderer_dialog_gtk.cc
index 682ab0d..2ca6699 100644
--- a/chrome/browser/gtk/hung_renderer_dialog_gtk.cc
+++ b/chrome/browser/gtk/hung_renderer_dialog_gtk.cc
@@ -6,11 +6,11 @@
#include <gtk/gtk.h>
+#include "app/gfx/gtk_util.h"
#include "app/l10n_util.h"
#include "app/resource_bundle.h"
#include "base/process_util.h"
#include "chrome/browser/browser_list.h"
-#include "chrome/common/gtk_util.h"
#include "chrome/common/logging_chrome.h"
#include "chrome/common/result_codes.h"
#include "grit/chromium_strings.h"
diff --git a/chrome/browser/gtk/infobar_container_gtk.cc b/chrome/browser/gtk/infobar_container_gtk.cc
index f560ca1..3623497 100644
--- a/chrome/browser/gtk/infobar_container_gtk.cc
+++ b/chrome/browser/gtk/infobar_container_gtk.cc
@@ -65,7 +65,7 @@ void InfoBarContainerGtk::ChangeTabContents(TabContents* contents) {
Source<TabContents>(tab_contents_));
}
- gfx::RemoveAllChildren(container_.get());
+ gtk_util::RemoveAllChildren(container_.get());
tab_contents_ = contents;
if (tab_contents_) {
diff --git a/chrome/browser/gtk/infobar_gtk.cc b/chrome/browser/gtk/infobar_gtk.cc
index fcee318..e129fa9 100644
--- a/chrome/browser/gtk/infobar_gtk.cc
+++ b/chrome/browser/gtk/infobar_gtk.cc
@@ -6,6 +6,7 @@
#include <gtk/gtk.h>
+#include "app/gfx/gtk_util.h"
#include "base/gfx/gtk_util.h"
#include "base/string_util.h"
#include "chrome/browser/gtk/custom_button.h"
@@ -49,8 +50,8 @@ InfoBar::InfoBar(InfoBarDelegate* delegate)
// Set the top border and background color.
gtk_widget_modify_bg(bg_box, GTK_STATE_NORMAL, &kBackgroundColor);
- border_bin_.Own(gfx::CreateGtkBorderBin(bg_box, &kBorderColor,
- 0, 1, 0, 0));
+ border_bin_.Own(gtk_util::CreateGtkBorderBin(bg_box, &kBorderColor,
+ 0, 1, 0, 0));
gtk_widget_set_size_request(border_bin_.get(), -1, kInfoBarHeight);
// Add the icon on the left, if any.
diff --git a/chrome/browser/gtk/menu_gtk.cc b/chrome/browser/gtk/menu_gtk.cc
index 5ffac91..6279b28 100644
--- a/chrome/browser/gtk/menu_gtk.cc
+++ b/chrome/browser/gtk/menu_gtk.cc
@@ -4,11 +4,11 @@
#include "chrome/browser/gtk/menu_gtk.h"
+#include "app/gfx/gtk_util.h"
#include "app/l10n_util.h"
#include "base/logging.h"
#include "base/stl_util-inl.h"
#include "base/string_util.h"
-#include "chrome/common/gtk_util.h"
#include "third_party/skia/include/core/SkBitmap.h"
MenuGtk::MenuGtk(MenuGtk::Delegate* delegate,