OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 #ifndef CHROME_BROWSER_UI_LIBGTK2UI_GTK2_UI_H_ | 5 #ifndef CHROME_BROWSER_UI_LIBGTK2UI_GTK2_UI_H_ |
6 #define CHROME_BROWSER_UI_LIBGTK2UI_GTK2_UI_H_ | 6 #define CHROME_BROWSER_UI_LIBGTK2UI_GTK2_UI_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 22 matching lines...) Expand all Loading... |
33 Gtk2UI(); | 33 Gtk2UI(); |
34 virtual ~Gtk2UI(); | 34 virtual ~Gtk2UI(); |
35 | 35 |
36 // ui::LinuxShellDialog: | 36 // ui::LinuxShellDialog: |
37 virtual ui::SelectFileDialog* CreateSelectFileDialog( | 37 virtual ui::SelectFileDialog* CreateSelectFileDialog( |
38 ui::SelectFileDialog::Listener* listener, | 38 ui::SelectFileDialog::Listener* listener, |
39 ui::SelectFilePolicy* policy) const OVERRIDE; | 39 ui::SelectFilePolicy* policy) const OVERRIDE; |
40 | 40 |
41 // ui::LinuxUI: | 41 // ui::LinuxUI: |
42 virtual bool UseNativeTheme() const OVERRIDE; | 42 virtual bool UseNativeTheme() const OVERRIDE; |
43 virtual gfx::Image* GetThemeImageNamed(int id) const OVERRIDE; | 43 virtual gfx::Image GetThemeImageNamed(int id) const OVERRIDE; |
44 virtual bool GetColor(int id, SkColor* color) const OVERRIDE; | 44 virtual bool GetColor(int id, SkColor* color) const OVERRIDE; |
45 virtual ui::NativeTheme* GetNativeTheme() const OVERRIDE; | 45 virtual ui::NativeTheme* GetNativeTheme() const OVERRIDE; |
46 | 46 |
47 private: | 47 private: |
48 typedef std::map<int, SkColor> ColorMap; | 48 typedef std::map<int, SkColor> ColorMap; |
49 typedef std::map<int, color_utils::HSL> TintMap; | 49 typedef std::map<int, color_utils::HSL> TintMap; |
50 typedef std::map<int, gfx::Image*> ImageCache; | 50 typedef std::map<int, gfx::Image> ImageCache; |
51 | 51 |
52 // This method returns the colors webkit will use for the scrollbars. When no | 52 // This method returns the colors webkit will use for the scrollbars. When no |
53 // colors are specified by the GTK+ theme, this function averages of the | 53 // colors are specified by the GTK+ theme, this function averages of the |
54 // thumb part and of the track colors. | 54 // thumb part and of the track colors. |
55 void GetScrollbarColors(GdkColor* thumb_active_color, | 55 void GetScrollbarColors(GdkColor* thumb_active_color, |
56 GdkColor* thumb_inactive_color, | 56 GdkColor* thumb_inactive_color, |
57 GdkColor* track_color); | 57 GdkColor* track_color); |
58 | 58 |
59 // Gets the name of the current icon theme and passes it to our low level XDG | 59 // Gets the name of the current icon theme and passes it to our low level XDG |
60 // integration. | 60 // integration. |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
157 } // namespace libgtk2ui | 157 } // namespace libgtk2ui |
158 | 158 |
159 // Access point to the GTK2 desktop system. This should be the only symbol that | 159 // Access point to the GTK2 desktop system. This should be the only symbol that |
160 // is exported in the library; everything else should be used through the | 160 // is exported in the library; everything else should be used through the |
161 // interface, because eventually this .so will be loaded through dlopen at | 161 // interface, because eventually this .so will be loaded through dlopen at |
162 // runtime so our main binary can conditionally load GTK2 or GTK3 or EFL or | 162 // runtime so our main binary can conditionally load GTK2 or GTK3 or EFL or |
163 // QT or whatever. | 163 // QT or whatever. |
164 LIBGTK2UI_EXPORT ui::LinuxUI* BuildGtk2UI(); | 164 LIBGTK2UI_EXPORT ui::LinuxUI* BuildGtk2UI(); |
165 | 165 |
166 #endif // CHROME_BROWSER_UI_LIBGTK2UI_GTK2_UI_H_ | 166 #endif // CHROME_BROWSER_UI_LIBGTK2UI_GTK2_UI_H_ |
OLD | NEW |