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

Side by Side Diff: chrome/browser/ui/libgtk2ui/gtk2_ui.cc

Issue 12395034: Write a NativeThemeGtk2 class for linux_aura. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove a bunch of colors Created 7 years, 9 months 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/libgtk2ui/gtk2_ui.h" 5 #include "chrome/browser/ui/libgtk2ui/gtk2_ui.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/i18n/rtl.h" 10 #include "base/i18n/rtl.h"
11 #include "base/logging.h" 11 #include "base/logging.h"
12 #include "base/nix/mime_util_xdg.h" 12 #include "base/nix/mime_util_xdg.h"
13 #include "base/stl_util.h" 13 #include "base/stl_util.h"
14 #include "chrome/browser/themes/theme_properties.h" 14 #include "chrome/browser/themes/theme_properties.h"
15 #include "chrome/browser/ui/libgtk2ui/chrome_gtk_frame.h" 15 #include "chrome/browser/ui/libgtk2ui/chrome_gtk_frame.h"
16 #include "chrome/browser/ui/libgtk2ui/gtk2_util.h" 16 #include "chrome/browser/ui/libgtk2ui/gtk2_util.h"
17 #include "chrome/browser/ui/libgtk2ui/native_theme_gtk2.h"
17 #include "chrome/browser/ui/libgtk2ui/select_file_dialog_impl.h" 18 #include "chrome/browser/ui/libgtk2ui/select_file_dialog_impl.h"
18 #include "chrome/browser/ui/libgtk2ui/skia_utils_gtk2.h" 19 #include "chrome/browser/ui/libgtk2ui/skia_utils_gtk2.h"
19 #include "grit/theme_resources.h" 20 #include "grit/theme_resources.h"
20 #include "grit/ui_resources.h" 21 #include "grit/ui_resources.h"
21 #include "third_party/skia/include/core/SkBitmap.h" 22 #include "third_party/skia/include/core/SkBitmap.h"
22 #include "third_party/skia/include/core/SkCanvas.h" 23 #include "third_party/skia/include/core/SkCanvas.h"
23 #include "third_party/skia/include/core/SkColor.h" 24 #include "third_party/skia/include/core/SkColor.h"
24 #include "third_party/skia/include/core/SkShader.h" 25 #include "third_party/skia/include/core/SkShader.h"
25 #include "ui/base/resource/resource_bundle.h" 26 #include "ui/base/resource/resource_bundle.h"
26 #include "ui/gfx/canvas.h" 27 #include "ui/gfx/canvas.h"
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
328 ColorMap::const_iterator it = colors_.find(id); 329 ColorMap::const_iterator it = colors_.find(id);
329 if (it != colors_.end()) { 330 if (it != colors_.end()) {
330 *color = it->second; 331 *color = it->second;
331 return true; 332 return true;
332 } 333 }
333 334
334 return false; 335 return false;
335 } 336 }
336 337
337 ui::NativeTheme* Gtk2UI::GetNativeTheme() const { 338 ui::NativeTheme* Gtk2UI::GetNativeTheme() const {
338 return NULL; 339 return NativeThemeGtk2::instance();
339 } 340 }
340 341
341 ui::SelectFileDialog* Gtk2UI::CreateSelectFileDialog( 342 ui::SelectFileDialog* Gtk2UI::CreateSelectFileDialog(
342 ui::SelectFileDialog::Listener* listener, 343 ui::SelectFileDialog::Listener* listener,
343 ui::SelectFilePolicy* policy) const { 344 ui::SelectFilePolicy* policy) const {
344 return SelectFileDialogImpl::Create(listener, policy); 345 return SelectFileDialogImpl::Create(listener, policy);
345 } 346 }
346 347
347 void Gtk2UI::GetScrollbarColors(GdkColor* thumb_active_color, 348 void Gtk2UI::GetScrollbarColors(GdkColor* thumb_active_color,
348 GdkColor* thumb_inactive_color, 349 GdkColor* thumb_inactive_color,
(...skipping 624 matching lines...) Expand 10 before | Expand all | Expand 10 after
973 974
974 void Gtk2UI::ClearAllThemeData() { 975 void Gtk2UI::ClearAllThemeData() {
975 STLDeleteValues(&gtk_images_); 976 STLDeleteValues(&gtk_images_);
976 } 977 }
977 978
978 } // namespace libgtk2ui 979 } // namespace libgtk2ui
979 980
980 ui::LinuxUI* BuildGtk2UI() { 981 ui::LinuxUI* BuildGtk2UI() {
981 return new libgtk2ui::Gtk2UI; 982 return new libgtk2ui::Gtk2UI;
982 } 983 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/libgtk2ui/libgtk2ui.gyp » ('j') | chrome/browser/ui/libgtk2ui/native_theme_gtk2.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698