OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 UI_BASE_RESOURCE_RESOURCE_BUNDLE_H_ | 5 #ifndef UI_BASE_RESOURCE_RESOURCE_BUNDLE_H_ |
6 #define UI_BASE_RESOURCE_RESOURCE_BUNDLE_H_ | 6 #define UI_BASE_RESOURCE_RESOURCE_BUNDLE_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "build/build_config.h" | 9 #include "build/build_config.h" |
10 | 10 |
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
156 #if defined(OS_WIN) | 156 #if defined(OS_WIN) |
157 // NOTE: This needs to be called before initializing the shared instance if | 157 // NOTE: This needs to be called before initializing the shared instance if |
158 // your resources are not stored in the executable. | 158 // your resources are not stored in the executable. |
159 static void SetResourcesDataDLL(HINSTANCE handle); | 159 static void SetResourcesDataDLL(HINSTANCE handle); |
160 | 160 |
161 // Loads and returns an icon from the app module. | 161 // Loads and returns an icon from the app module. |
162 HICON LoadThemeIcon(int icon_id); | 162 HICON LoadThemeIcon(int icon_id); |
163 | 163 |
164 // Loads and returns a cursor from the app module. | 164 // Loads and returns a cursor from the app module. |
165 HCURSOR LoadCursor(int cursor_id); | 165 HCURSOR LoadCursor(int cursor_id); |
166 #elif defined(USE_X11) | 166 #elif defined(TOOLKIT_USES_GTK) |
167 // Gets the GdkPixbuf with the specified resource_id from the main data pak | 167 // Gets the GdkPixbuf with the specified resource_id from the main data pak |
168 // file. Returns a pointer to a shared instance of the GdkPixbuf. This | 168 // file. Returns a pointer to a shared instance of the GdkPixbuf. This |
169 // shared GdkPixbuf is owned by the resource bundle and should not be freed. | 169 // shared GdkPixbuf is owned by the resource bundle and should not be freed. |
170 // | 170 // |
171 // The bitmap is assumed to exist. This function will log in release, and | 171 // The bitmap is assumed to exist. This function will log in release, and |
172 // assert in debug mode if it does not. On failure, this will return a | 172 // assert in debug mode if it does not. On failure, this will return a |
173 // pointer to a shared empty placeholder bitmap so it will be visible what | 173 // pointer to a shared empty placeholder bitmap so it will be visible what |
174 // is missing. | 174 // is missing. |
175 // This function flips it in RTL locales. | 175 // This function flips it in RTL locales. |
176 GdkPixbuf* GetRTLEnabledPixbufNamed(int resource_id); | 176 GdkPixbuf* GetRTLEnabledPixbufNamed(int resource_id); |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
310 | 310 |
311 DISALLOW_COPY_AND_ASSIGN(ResourceBundle); | 311 DISALLOW_COPY_AND_ASSIGN(ResourceBundle); |
312 }; | 312 }; |
313 | 313 |
314 } // namespace ui | 314 } // namespace ui |
315 | 315 |
316 // TODO(beng): Someday, maybe, get rid of this. | 316 // TODO(beng): Someday, maybe, get rid of this. |
317 using ui::ResourceBundle; | 317 using ui::ResourceBundle; |
318 | 318 |
319 #endif // UI_BASE_RESOURCE_RESOURCE_BUNDLE_H_ | 319 #endif // UI_BASE_RESOURCE_RESOURCE_BUNDLE_H_ |
OLD | NEW |