]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/grid.i
updated Joystick demo, is now wxDesigner-less
[wxWidgets.git] / wxPython / src / grid.i
index a689b9af833a9de33309d676caa8c3eb8c18876c..cebed93efa21a7d169a702f07617d6adbba83573 100644 (file)
@@ -20,9 +20,6 @@
 #include <wx/grid.h>
 #include <wx/generic/gridctrl.h>
 
-    DECLARE_DEF_STRING(PanelNameStr);
-    DECLARE_DEF_STRING2(DateTimeFormatStr, wxT("%c"));
-    static const wxString wxPyEmptyString(wxT(""));
 %}
 
 
 %import windows.i
 %pythoncode { wx = core }
 
+
 %include _grid_rename.i
 
+MAKE_CONST_WXSTRING_NOSWIG(EmptyString);
+MAKE_CONST_WXSTRING_NOSWIG(PanelNameStr);
+MAKE_CONST_WXSTRING2(DateTimeFormatStr, wxT("%c"));
+
+
 //---------------------------------------------------------------------------
 // OOR related typemaps and helper functions
 
@@ -1540,9 +1543,16 @@ public:
             const wxString& name = wxPyPanelNameStr);
 
 
-    enum wxGridSelectionModes {wxGridSelectCells,
-                               wxGridSelectRows,
-                               wxGridSelectColumns};
+    enum wxGridSelectionModes {
+        wxGridSelectCells,
+        wxGridSelectRows,
+        wxGridSelectColumns
+    };
+    %pythoncode {
+        SelectCells =   wxGridSelectCells
+        SelectRows =    wxGridSelectRows
+        SelectColumns = wxGridSelectColumns,
+    }
 
     bool CreateGrid( int numRows, int numCols,
                      WXGRIDSELECTIONMODES selmode = wxGrid::wxGridSelectCells );