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

Unified Diff: app/resource_bundle.h

Issue 173363: Add a helper to resource bundle to get an NSImage back.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | app/resource_bundle_mac.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: app/resource_bundle.h
===================================================================
--- app/resource_bundle.h (revision 24269)
+++ app/resource_bundle.h (working copy)
@@ -35,6 +35,14 @@
typedef uint32 SkColor;
class StringPiece;
+#if defined(OS_MACOSX)
+#ifdef __OBJC__
+@class NSImage;
+#else
+class NSImage;
+#endif // __OBJC__
+#endif // defined(OS_MACOSX)
+
// ResourceBundle is a central facility to load images and other resources,
// such as theme graphics.
// Every resource is loaded only once.
@@ -112,6 +120,9 @@
// Loads and returns a cursor from the app module.
HCURSOR LoadCursor(int cursor_id);
+#elif defined(OS_MACOSX)
+ // Wrapper for GetBitmapNamed. Converts the bitmap to an autoreleased NSImage.
+ NSImage* GetNSImageNamed(int resource_id);
#elif defined(OS_LINUX)
// Gets the GdkPixbuf with the specified resource_id, first by looking into
// the theme data, than in the current module data if applicable. Returns a
« no previous file with comments | « no previous file | app/resource_bundle_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698