]> git.saurik.com Git - wxWidgets.git/blobdiff - utils/wxPython/src/clip_dnd.i
More updates to wxWindow, wxMenu, GdiImage to get minimal to work
[wxWidgets.git] / utils / wxPython / src / clip_dnd.i
index 7def4d37dfcb4e90a37d475b5ebf106ccf08ff53..e054bedf2499912a5e53705f487e9893a295873b 100644 (file)
@@ -376,6 +376,7 @@ public:
 };
 
 %{
+    // See below in the init function...
     wxClipboard* wxPyTheClipboard;
 %}
 %readonly
@@ -400,11 +401,18 @@ bool wxIsDragResultOk(wxDragResult res);
 %{
 class wxPyDropSource : public wxDropSource {
 public:
+#ifdef __WXMSW__
     wxPyDropSource(wxWindow *win = NULL,
                    const wxCursor &cursorCopy = wxNullCursor,
                    const wxCursor &cursorMove = wxNullCursor,
                    const wxCursor &cursorStop = wxNullCursor)
         : wxDropSource(win, cursorCopy, cursorMove, cursorStop) {}
+#else
+    wxPyDropSource(wxWindow *win = NULL,
+                   const wxIcon &go = wxNullIcon)
+        : wxDropSource(win, go) {}
+#endif
+    ~wxPyDropSource() { }
 
     DEC_PYCALLBACK_BOOL_DR(GiveFeedback);
     PYPRIVATE;
@@ -417,12 +425,18 @@ IMP_PYCALLBACK_BOOL_DR(wxPyDropSource, wxDropSource, GiveFeedback);
 
 %name(wxDropSource) class wxPyDropSource {
 public:
+#ifdef __WXMSW__
     wxPyDropSource(wxWindow *win = NULL,
                  const wxCursor &cursorCopy = wxNullCursor,
                  const wxCursor &cursorMove = wxNullCursor,
                  const wxCursor &cursorStop = wxNullCursor);
-    void _setSelf(PyObject* self);
-    %pragma(python) addtomethod = "__init__:self._setSelf(self)"
+#else
+    wxPyDropSource(wxWindow *win = NULL,
+                   const wxIcon &go = wxNullIcon);
+#endif
+
+    void _setSelf(PyObject* self, int incref);
+    %pragma(python) addtomethod = "__init__:self._setSelf(self, 0)"
     ~wxPyDropSource();
 
     void SetData(wxDataObject& data);