]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/utils.cpp
Applied patch [ 805147 ] GDI objects are not deselected from DC
[wxWidgets.git] / src / mac / utils.cpp
index 4301e543230deb1f4f2cf4d1ea1c04bb7cc129c8..780fee8956c3f3509b929bba81acff1aeb4336d1 100644 (file)
     #include <wtime.h>
 #endif
 
+// ---------------------------------------------------------------------------
+// code used in both base and GUI compilation
+// ---------------------------------------------------------------------------
+
+// our OS version is the same in non GUI and GUI cases
+static int DoGetOSVersion(int *majorVsn, int *minorVsn)
+{
+    long theSystem ;
+
+    // are there x-platform conventions ?
+
+    Gestalt(gestaltSystemVersion, &theSystem) ;
+    if (minorVsn != NULL) {
+        *minorVsn = (theSystem & 0xFF ) ;
+    }
+    if (majorVsn != NULL) {
+        *majorVsn = (theSystem >> 8 ) ;
+    }
+#ifdef __DARWIN__
+    return wxMAC_DARWIN;
+#else
+    return wxMAC;
+#endif
+}
+
 #if wxUSE_BASE
 
 #ifndef __DARWIN__
@@ -197,27 +222,6 @@ void wxBell()
     SysBeep(30);
 }
 
-// our OS version is the same in non GUI and GUI cases
-static int DoGetOSVersion(int *majorVsn, int *minorVsn)
-{
-    long theSystem ;
-
-    // are there x-platform conventions ?
-
-    Gestalt(gestaltSystemVersion, &theSystem) ;
-    if (minorVsn != NULL) {
-        *minorVsn = (theSystem & 0xFF ) ;
-    }
-    if (majorVsn != NULL) {
-        *majorVsn = (theSystem >> 8 ) ;
-    }
-#ifdef __DARWIN__
-    return wxMAC_DARWIN;
-#else
-    return wxMAC;
-#endif
-}
-
 wxToolkitInfo& wxConsoleAppTraits::GetToolkitInfo()
 {
     static wxToolkitInfo info;
@@ -482,7 +486,7 @@ wxString wxGetOsDescription()
 {
 #ifdef WXWIN_OS_DESCRIPTION
     // use configure generated description if available
-    return wxString("MacOS (") + WXWIN_OS_DESCRIPTION + wxString(")");
+    return wxString(wxT("MacOS (")) + wxT(WXWIN_OS_DESCRIPTION) + wxString(wxT(")"));
 #else
     return wxT("MacOS") ; //TODO:define further
 #endif