]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/osx/core/cfstring.h
fix wxOS2 build where OpenGL headers are available but there's no wxGlCanvas implemen...
[wxWidgets.git] / include / wx / osx / core / cfstring.h
index 523b5f34624a8d15f0275630673e7b534567ebeb..2cd04a9d7622b3d3a6eb280e8f23a677a889f55e 100644 (file)
@@ -41,6 +41,13 @@ public:
     wxCFStringRef(const wxString &str,
                         wxFontEncoding encoding = wxFONTENCODING_DEFAULT) ;
 
+#if wxOSX_USE_COCOA_OR_IPHONE
+    wxCFStringRef(NSString* ref)
+        : wxCFRef< CFStringRef >((CFStringRef) ref) 
+    {
+    }
+#endif
+
     wxCFStringRef(CFStringRef ref)
         : wxCFRef< CFStringRef >(ref) 
     {
@@ -57,6 +64,9 @@ public:
 
     wxString AsString( wxFontEncoding encoding = wxFONTENCODING_DEFAULT ) ;
 
+#if wxOSX_USE_COCOA_OR_IPHONE
+    NSString* AsNSString() const { return (NSString*)(CFStringRef) *this; }
+#endif
 private:
 } ;