]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/demo/GridDragable.py
Fix "warning: operation on 'y' may be undefined".
[wxWidgets.git] / wxPython / demo / GridDragable.py
index 547b19ee94918daabfe754d6270869243d1455da..8f375b8eb7124ad24dc888ac32ba44381b0ea836 100644 (file)
@@ -1,13 +1,3 @@
-# 11/6/2003 - Jeff Grimmett (grimmtooth@softhome.net)
-#
-# o Modified for V2.5
-#
-# 11/25/2003 - Jeff Grimmett (grimmtooth@softhome.net)
-#
-# o wx renamer didn't appear to 'catch' all the classes in 
-#   wx.lib.gridmovers
-# o Event binder not working properly with wx.lib.gridmovers
-#
 
 import  wx
 import  wx.grid             as  gridlib
@@ -176,16 +166,12 @@ class DragableGrid(gridlib.Grid):
         self.SetTable(table, True)
 
         # Enable Column moving
-        #>> TODO - renamer didn't get this one
-        gridmovers.wxGridColMover(self)
-        #>> TODO - Bind() not working here
-        gridmovers.EVT_GRID_COL_MOVE(self,self.GetId(),self.OnColMove)
+        gridmovers.GridColMover(self)
+        self.Bind(gridmovers.EVT_GRID_COL_MOVE, self.OnColMove, self)
 
         # Enable Row moving
-        #>> TODO - renamer didn't get this one
-        gridmovers.wxGridRowMover(self)
-        #>> TODO - Bind() not working here
-        gridmovers.EVT_GRID_ROW_MOVE(self,self.GetId(),self.OnRowMove)
+        gridmovers.GridRowMover(self)
+        self.Bind(gridmovers.EVT_GRID_ROW_MOVE, self.OnRowMove, self)
 
     # Event method called when a column move needs to take place
     def OnColMove(self,evt):