]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/mac/_gdi_wrap.cpp
Lock whole screen when popup is open under GTK+.
[wxWidgets.git] / wxPython / src / mac / _gdi_wrap.cpp
index 17775d788ab2ee2f2a89d64bff487798c7e56ad7..8e18bcd8485386dad984b4b7a9cb918724e9d4e5 100644 (file)
@@ -1920,12 +1920,14 @@ SWIG_Check_long(PyObject* obj)
   return SWIG_AsVal_long(obj, (long*)0);
 }
 
-static wxCursor *new_wxCursor(wxString const *cursorName,long type,int hotSpotX=0,int hotSpotY=0){
+static wxCursor *new_wxCursor(wxString const &cursorName,long type,int hotSpotX=0,int hotSpotY=0){
 #ifdef __WXGTK__
-            wxCHECK_MSG(false, NULL,
-                        wxT("wx.Cursor constructor not implemented for wxGTK, use wx.StockCursor, wx.CursorFromImage, or wx.CursorFromBits instead."));
+            wxImage img(cursorName, type);
+            img.SetOption(wxIMAGE_OPTION_CUR_HOTSPOT_X, hotSpotX);
+            img.SetOption(wxIMAGE_OPTION_CUR_HOTSPOT_Y, hotSpotY);
+            return new wxCursor(img);
 #else
-            return new wxCursor(*cursorName, type, hotSpotX, hotSpotY);
+            return new wxCursor(cursorName, type, hotSpotX, hotSpotY);
 #endif
         }
 
@@ -5907,7 +5909,7 @@ static PyObject * IconBundle_swigregister(PyObject *, PyObject *args) {
 }
 static PyObject *_wrap_new_Cursor(PyObject *, PyObject *args, PyObject *kwargs) {
     PyObject *resultobj;
-    wxString *arg1 = (wxString *) 0 ;
+    wxString *arg1 = 0 ;
     long arg2 ;
     int arg3 = (int) 0 ;
     int arg4 = (int) 0 ;
@@ -5946,7 +5948,7 @@ static PyObject *_wrap_new_Cursor(PyObject *, PyObject *args, PyObject *kwargs)
     {
         if (!wxPyCheckForApp()) SWIG_fail;
         PyThreadState* __tstate = wxPyBeginAllowThreads();
-        result = (wxCursor *)new_wxCursor((wxString const *)arg1,arg2,arg3,arg4);
+        result = (wxCursor *)new_wxCursor((wxString const &)*arg1,arg2,arg3,arg4);
         
         wxPyEndAllowThreads(__tstate);
         if (PyErr_Occurred()) SWIG_fail;