]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/mac/utils.cpp
applied SourceForge patch # 544164 (hidden virtual method in wxMenuBar)
[wxWidgets.git] / wxPython / src / mac / utils.cpp
index afcd6bf1a483cc6fec3a880804dc233feb78dd6f..4cefd4da5610745ff228b90a9f6f0394b4137677 100644 (file)
@@ -55,14 +55,13 @@ extern PyObject *SWIG_newvarlink(void);
 
 #define SWIG_name    "utilsc"
 
 
 #define SWIG_name    "utilsc"
 
-#include "export.h"
+#include "helpers.h"
 #include <wx/config.h>
 #include <wx/fileconf.h>
 #include <wx/datetime.h>
 
     // Put some wx default wxChar* values into wxStrings.
 #include <wx/config.h>
 #include <wx/fileconf.h>
 #include <wx/datetime.h>
 
     // Put some wx default wxChar* values into wxStrings.
-    static const wxChar* wxDateFormatStr = wxT("sashWindow");
-    DECLARE_DEF_STRING(DateFormatStr);
+    DECLARE_DEF_STRING2(DateFormatStr, wxT("%c"));
     static const wxString wxPyEmptyString(wxT(""));
 
 
     static const wxString wxPyEmptyString(wxT(""));
 
 
@@ -5086,9 +5085,10 @@ static PyObject *_wrap_wxDateTime___sub__DS(PyObject *self, PyObject *args, PyOb
     return _resultobj;
 }
 
     return _resultobj;
 }
 
-static int  wxDateTime___cmp__(wxDateTime *self,const wxDateTime & other) {
-            if (*self <  other) return -1;
-            if (*self == other) return 0;
+static int  wxDateTime___cmp__(wxDateTime *self,const wxDateTime * other) {
+            if (! other) return -1;
+            if (*self <  *other) return -1;
+            if (*self == *other) return 0;
             return 1;
         }
 static PyObject *_wrap_wxDateTime___cmp__(PyObject *self, PyObject *args, PyObject *kwargs) {
             return 1;
         }
 static PyObject *_wrap_wxDateTime___cmp__(PyObject *self, PyObject *args, PyObject *kwargs) {
@@ -5119,7 +5119,7 @@ static PyObject *_wrap_wxDateTime___cmp__(PyObject *self, PyObject *args, PyObje
     }
 {
     PyThreadState* __tstate = wxPyBeginAllowThreads();
     }
 {
     PyThreadState* __tstate = wxPyBeginAllowThreads();
-    _result = (int )wxDateTime___cmp__(_arg0,*_arg1);
+    _result = (int )wxDateTime___cmp__(_arg0,_arg1);
 
     wxPyEndAllowThreads(__tstate);
     if (PyErr_Occurred()) return NULL;
 
     wxPyEndAllowThreads(__tstate);
     if (PyErr_Occurred()) return NULL;
@@ -6220,9 +6220,10 @@ static PyObject *_wrap_wxTimeSpan___neg__(PyObject *self, PyObject *args, PyObje
     return _resultobj;
 }
 
     return _resultobj;
 }
 
-static int  wxTimeSpan___cmp__(wxTimeSpan *self,const wxTimeSpan & other) {
-            if (*self <  other) return -1;
-            if (*self == other) return 0;
+static int  wxTimeSpan___cmp__(wxTimeSpan *self,const wxTimeSpan * other) {
+            if (! other) return -1;
+            if (*self <  *other) return -1;
+            if (*self == *other) return 0;
             return 1;
         }
 static PyObject *_wrap_wxTimeSpan___cmp__(PyObject *self, PyObject *args, PyObject *kwargs) {
             return 1;
         }
 static PyObject *_wrap_wxTimeSpan___cmp__(PyObject *self, PyObject *args, PyObject *kwargs) {
@@ -6253,7 +6254,7 @@ static PyObject *_wrap_wxTimeSpan___cmp__(PyObject *self, PyObject *args, PyObje
     }
 {
     PyThreadState* __tstate = wxPyBeginAllowThreads();
     }
 {
     PyThreadState* __tstate = wxPyBeginAllowThreads();
-    _result = (int )wxTimeSpan___cmp__(_arg0,*_arg1);
+    _result = (int )wxTimeSpan___cmp__(_arg0,_arg1);
 
     wxPyEndAllowThreads(__tstate);
     if (PyErr_Occurred()) return NULL;
 
     wxPyEndAllowThreads(__tstate);
     if (PyErr_Occurred()) return NULL;
@@ -7882,8 +7883,9 @@ SWIGEXPORT(void) initutilsc() {
         PyDict_SetItemString(d,"wxCONFIG_USE_GLOBAL_FILE", PyInt_FromLong((long) wxCONFIG_USE_GLOBAL_FILE));
         PyDict_SetItemString(d,"wxCONFIG_USE_RELATIVE_PATH", PyInt_FromLong((long) wxCONFIG_USE_RELATIVE_PATH));
 
         PyDict_SetItemString(d,"wxCONFIG_USE_GLOBAL_FILE", PyInt_FromLong((long) wxCONFIG_USE_GLOBAL_FILE));
         PyDict_SetItemString(d,"wxCONFIG_USE_RELATIVE_PATH", PyInt_FromLong((long) wxCONFIG_USE_RELATIVE_PATH));
 
-    wxClassInfo::CleanUpClasses();
-    wxClassInfo::InitializeClasses();
+    // These are no longer needed since utils is back in the core
+//      wxClassInfo::CleanUpClasses();
+//      wxClassInfo::InitializeClasses();
         PyDict_SetItemString(d,"wxConfigBase_Type_Unknown", PyInt_FromLong((long) wxConfigBase::Type_Unknown));
         PyDict_SetItemString(d,"wxConfigBase_Type_String", PyInt_FromLong((long) wxConfigBase::Type_String));
         PyDict_SetItemString(d,"wxConfigBase_Type_Boolean", PyInt_FromLong((long) wxConfigBase::Type_Boolean));
         PyDict_SetItemString(d,"wxConfigBase_Type_Unknown", PyInt_FromLong((long) wxConfigBase::Type_Unknown));
         PyDict_SetItemString(d,"wxConfigBase_Type_String", PyInt_FromLong((long) wxConfigBase::Type_String));
         PyDict_SetItemString(d,"wxConfigBase_Type_Boolean", PyInt_FromLong((long) wxConfigBase::Type_Boolean));