X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/704eda0cdc33dfb009dfd578fdf78ee29e159f23..7e664d85e6512d807ce2eb186ed9e0bbd60d6e8b:/wxPython/src/msw/_windows_wrap.cpp diff --git a/wxPython/src/msw/_windows_wrap.cpp b/wxPython/src/msw/_windows_wrap.cpp index 3d44ad48dc..334673d7c9 100644 --- a/wxPython/src/msw/_windows_wrap.cpp +++ b/wxPython/src/msw/_windows_wrap.cpp @@ -985,6 +985,10 @@ typedef struct swig_const_info { /* Common SWIG API */ +#if PY_VERSION_HEX < 0x02050000 +typedef int Py_ssize_t; +#endif + /* for raw pointers */ #define SWIG_Python_ConvertPtr(obj, pptr, type, flags) SWIG_Python_ConvertPtrAndOwn(obj, pptr, type, flags, 0) #define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Python_ConvertPtr(obj, pptr, type, flags) @@ -2048,7 +2052,7 @@ SWIG_Python_ConvertFunctionPtr(PyObject *obj, void **ptr, swig_type_info *ty) { void *vptr = 0; /* here we get the method pointer for callbacks */ - char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc); + const char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc); const char *desc = doc ? strstr(doc, "swig_ptr: ") : 0; if (desc) { desc = ty ? SWIG_UnpackVoidPtr(desc + 10, &vptr, ty->name) : 0; @@ -3222,6 +3226,10 @@ SWIGINTERN void wxPyTaskBarIcon_Destroy(wxPyTaskBarIcon *self){ static const wxString wxPyFileSelectorDefaultWildcardStr(wxFileSelectorDefaultWildcardStr); static const wxString wxPyGetTextFromUserPromptStr(wxGetTextFromUserPromptStr); static const wxString wxPyMessageBoxCaptionStr(wxMessageBoxCaptionStr); + +// for compatibility only +#define wxHIDE_READONLY 0 + SWIGINTERN PyObject *wxFileDialog_GetFilenames(wxFileDialog *self){ wxArrayString arr; self->GetFilenames(arr); @@ -33555,11 +33563,11 @@ extern "C" { swig_type_info **types_initial) { size_t i; for (i = 0; methods[i].ml_name; ++i) { - char *c = methods[i].ml_doc; + const char *c = methods[i].ml_doc; if (c && (c = strstr(c, "swig_ptr: "))) { int j; swig_const_info *ci = 0; - char *name = c + 10; + const char *name = c + 10; for (j = 0; const_table[j].type; ++j) { if (strncmp(const_table[j].name, name, strlen(const_table[j].name)) == 0) { @@ -33744,6 +33752,7 @@ SWIGEXPORT void SWIG_init(void) { SWIG_Python_SetConstant(d, "FILE_MUST_EXIST",SWIG_From_int(static_cast< int >(wxFILE_MUST_EXIST))); SWIG_Python_SetConstant(d, "MULTIPLE",SWIG_From_int(static_cast< int >(wxMULTIPLE))); SWIG_Python_SetConstant(d, "CHANGE_DIR",SWIG_From_int(static_cast< int >(wxCHANGE_DIR))); + SWIG_Python_SetConstant(d, "HIDE_READONLY",SWIG_From_int(static_cast< int >(wxHIDE_READONLY))); SWIG_Python_SetConstant(d, "FD_OPEN",SWIG_From_int(static_cast< int >(wxFD_OPEN))); SWIG_Python_SetConstant(d, "FD_SAVE",SWIG_From_int(static_cast< int >(wxFD_SAVE))); SWIG_Python_SetConstant(d, "FD_OVERWRITE_PROMPT",SWIG_From_int(static_cast< int >(wxFD_OVERWRITE_PROMPT)));