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_LIBGTKUI_GTK_UI_H_ | 5 #ifndef CHROME_BROWSER_UI_LIBGTKUI_GTK_UI_H_ |
6 #define CHROME_BROWSER_UI_LIBGTKUI_GTK_UI_H_ | 6 #define CHROME_BROWSER_UI_LIBGTKUI_GTK_UI_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <memory> | 9 #include <memory> |
10 #include <vector> | 10 #include <vector> |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 // thumb part and of the track colors. | 115 // thumb part and of the track colors. |
116 void SetScrollbarColors(); | 116 void SetScrollbarColors(); |
117 | 117 |
118 // Extracts colors and tints from the GTK theme, both for the | 118 // Extracts colors and tints from the GTK theme, both for the |
119 // ThemeService interface and the colors we send to webkit. | 119 // ThemeService interface and the colors we send to webkit. |
120 void LoadGtkValues(); | 120 void LoadGtkValues(); |
121 | 121 |
122 // Sets the Xcursor theme and size with the GTK theme and size. | 122 // Sets the Xcursor theme and size with the GTK theme and size. |
123 void UpdateCursorTheme(); | 123 void UpdateCursorTheme(); |
124 | 124 |
125 // Reads in explicit theme frame colors from the ChromeGtkFrame style class | |
126 // or generates them per our fallback algorithm. | |
127 void BuildFrameColors(); | |
128 | |
129 // Updates |default_font_*|. | 125 // Updates |default_font_*|. |
130 void UpdateDefaultFont(); | 126 void UpdateDefaultFont(); |
131 | 127 |
132 // Gets a ChromeGtkFrame theme color; returns true on success. No-op on gtk3. | 128 // Gets a ChromeGtkFrame theme color; returns true on success. No-op on gtk3. |
133 bool GetChromeStyleColor(const char* sytle_property, | 129 bool GetChromeStyleColor(const char* sytle_property, |
134 SkColor* ret_color) const; | 130 SkColor* ret_color) const; |
135 | 131 |
136 ui::NativeTheme* native_theme_; | 132 ui::NativeTheme* native_theme_; |
137 | 133 |
138 // A GtkWindow object with the class "ChromeGtkFrame". | 134 // A GtkWindow object with the class "ChromeGtkFrame". |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
194 } // namespace libgtkui | 190 } // namespace libgtkui |
195 | 191 |
196 // Access point to the GTK2 desktop system. This should be the only symbol that | 192 // Access point to the GTK2 desktop system. This should be the only symbol that |
197 // is exported in the library; everything else should be used through the | 193 // is exported in the library; everything else should be used through the |
198 // interface, because eventually this .so will be loaded through dlopen at | 194 // interface, because eventually this .so will be loaded through dlopen at |
199 // runtime so our main binary can conditionally load GTK2 or GTK3 or EFL or | 195 // runtime so our main binary can conditionally load GTK2 or GTK3 or EFL or |
200 // QT or whatever. | 196 // QT or whatever. |
201 LIBGTKUI_EXPORT views::LinuxUI* BuildGtkUi(); | 197 LIBGTKUI_EXPORT views::LinuxUI* BuildGtkUi(); |
202 | 198 |
203 #endif // CHROME_BROWSER_UI_LIBGTKUI_GTK_UI_H_ | 199 #endif // CHROME_BROWSER_UI_LIBGTKUI_GTK_UI_H_ |
OLD | NEW |