]> git.saurik.com Git - wxWidgets.git/blobdiff - utils/wxPython/src/msw/windows2.py
*** empty log message ***
[wxWidgets.git] / utils / wxPython / src / msw / windows2.py
index bc40f105909b2ccf07c6ef61ea2393e8b329b26f..9af0e32ba93ef671731fe45060679cb3d358edb9 100644 (file)
@@ -10,12 +10,12 @@ from windows import *
 from controls import *
 
 from events import *
-import wxp
+import wx
 class wxGridCellPtr :
     def __init__(self,this):
         self.this = this
         self.thisown = 0
-    def __del__(self):
+    def __del__(self, windows2c=windows2c):
         if self.thisown == 1 :
             windows2c.delete_wxGridCell(self.this)
     def GetTextValue(self):
@@ -127,6 +127,9 @@ class wxGridPtr(wxPanelPtr):
         val = windows2c.wxGrid_GetDefCellBackgroundColour(self.this)
         val = wxColourPtr(val)
         return val
+    def GetCells(self):
+        val = windows2c.wxGrid_GetCells(self.this)
+        return val
     def GetCellTextColour(self,arg0,arg1):
         val = windows2c.wxGrid_GetCellTextColour(self.this,arg0,arg1)
         val = wxColourPtr(val)
@@ -155,6 +158,7 @@ class wxGridPtr(wxPanelPtr):
     def GetCurrentRect(self):
         val = windows2c.wxGrid_GetCurrentRect(self.this)
         val = wxRectPtr(val)
+        val.thisown = 1
         return val
     def GetCursorColumn(self):
         val = windows2c.wxGrid_GetCursorColumn(self.this)
@@ -282,6 +286,12 @@ class wxGridPtr(wxPanelPtr):
     def UpdateDimensions(self):
         val = windows2c.wxGrid_UpdateDimensions(self.this)
         return val
+    def GetEditInPlace(self):
+        val = windows2c.wxGrid_GetEditInPlace(self.this)
+        return val
+    def SetEditInPlace(self,*args):
+        val = apply(windows2c.wxGrid_SetEditInPlace,(self.this,)+args)
+        return val
     def __repr__(self):
         return "<C wxGrid instance>"
 class wxGrid(wxGridPtr):
@@ -294,16 +304,16 @@ class wxGrid(wxGridPtr):
         args = tuple(argl)
         self.this = apply(windows2c.new_wxGrid,(arg0.this,arg1,)+args)
         self.thisown = 1
-        wxp._StdWindowCallbacks(self)
-        wxp._checkForCallback(self, 'OnSelectCell',           wxEVT_GRID_SELECT_CELL)
-        wxp._checkForCallback(self, 'OnCreateCell',           wxEVT_GRID_CREATE_CELL)
-        wxp._checkForCallback(self, 'OnChangeLabels',         wxEVT_GRID_CHANGE_LABELS)
-        wxp._checkForCallback(self, 'OnChangeSelectionLabel', wxEVT_GRID_CHANGE_SEL_LABEL)
-        wxp._checkForCallback(self, 'OnCellChange',           wxEVT_GRID_CELL_CHANGE)
-        wxp._checkForCallback(self, 'OnCellLeftClick',        wxEVT_GRID_CELL_LCLICK)
-        wxp._checkForCallback(self, 'OnCellRightClick',       wxEVT_GRID_CELL_RCLICK)
-        wxp._checkForCallback(self, 'OnLabelLeftClick',       wxEVT_GRID_LABEL_LCLICK)
-        wxp._checkForCallback(self, 'OnLabelRightClick',      wxEVT_GRID_LABEL_RCLICK)
+        wx._StdWindowCallbacks(self)
+        wx._checkForCallback(self, 'OnSelectCell',           wxEVT_GRID_SELECT_CELL)
+        wx._checkForCallback(self, 'OnCreateCell',           wxEVT_GRID_CREATE_CELL)
+        wx._checkForCallback(self, 'OnChangeLabels',         wxEVT_GRID_CHANGE_LABELS)
+        wx._checkForCallback(self, 'OnChangeSelectionLabel', wxEVT_GRID_CHANGE_SEL_LABEL)
+        wx._checkForCallback(self, 'OnCellChange',           wxEVT_GRID_CELL_CHANGE)
+        wx._checkForCallback(self, 'OnCellLeftClick',        wxEVT_GRID_CELL_LCLICK)
+        wx._checkForCallback(self, 'OnCellRightClick',       wxEVT_GRID_CELL_RCLICK)
+        wx._checkForCallback(self, 'OnLabelLeftClick',       wxEVT_GRID_LABEL_LCLICK)
+        wx._checkForCallback(self, 'OnLabelRightClick',      wxEVT_GRID_LABEL_RCLICK)
 
 
 
@@ -360,7 +370,7 @@ class wxGridEvent(wxGridEventPtr):
 
 
 
-class wxNotebookEventPtr(wxCommandEventPtr):
+class wxNotebookEventPtr(wxNotifyEventPtr):
     def __init__(self,this):
         self.this = this
         self.thisown = 0
@@ -370,6 +380,12 @@ class wxNotebookEventPtr(wxCommandEventPtr):
     def GetOldSelection(self):
         val = windows2c.wxNotebookEvent_GetOldSelection(self.this)
         return val
+    def SetOldSelection(self,arg0):
+        val = windows2c.wxNotebookEvent_SetOldSelection(self.this,arg0)
+        return val
+    def SetSelection(self,arg0):
+        val = windows2c.wxNotebookEvent_SetSelection(self.this,arg0)
+        return val
     def __repr__(self):
         return "<C wxNotebookEvent instance>"
 class wxNotebookEvent(wxNotebookEventPtr):
@@ -402,10 +418,11 @@ class wxNotebookPtr(wxControlPtr):
         val = windows2c.wxNotebook_GetPageText(self.this,arg0)
         return val
     def SetImageList(self,arg0):
-        val = windows2c.wxNotebook_SetImageList(self.this,arg0)
+        val = windows2c.wxNotebook_SetImageList(self.this,arg0.this)
         return val
     def GetImageList(self):
         val = windows2c.wxNotebook_GetImageList(self.this)
+        val = wxImageListPtr(val)
         return val
     def GetPageImage(self,arg0):
         val = windows2c.wxNotebook_GetPageImage(self.this,arg0)
@@ -419,6 +436,9 @@ class wxNotebookPtr(wxControlPtr):
     def DeletePage(self,arg0):
         val = windows2c.wxNotebook_DeletePage(self.this,arg0)
         return val
+    def RemovePage(self,arg0):
+        val = windows2c.wxNotebook_RemovePage(self.this,arg0)
+        return val
     def DeleteAllPages(self):
         val = windows2c.wxNotebook_DeleteAllPages(self.this)
         return val
@@ -430,6 +450,10 @@ class wxNotebookPtr(wxControlPtr):
         return val
     def GetPage(self,arg0):
         val = windows2c.wxNotebook_GetPage(self.this,arg0)
+        val = wxWindowPtr(val)
+        return val
+    def ResizeChildren(self):
+        val = windows2c.wxNotebook_ResizeChildren(self.this)
         return val
     def __repr__(self):
         return "<C wxNotebook instance>"
@@ -443,7 +467,36 @@ class wxNotebook(wxNotebookPtr):
         args = tuple(argl)
         self.this = apply(windows2c.new_wxNotebook,(arg0.this,arg1,)+args)
         self.thisown = 1
-        wxp._StdWindowCallbacks(self)
+        wx._StdWindowCallbacks(self)
+
+
+
+
+class wxSplitterEventPtr(wxCommandEventPtr):
+    def __init__(self,this):
+        self.this = this
+        self.thisown = 0
+    def GetSashPosition(self):
+        val = windows2c.wxSplitterEvent_GetSashPosition(self.this)
+        return val
+    def GetX(self):
+        val = windows2c.wxSplitterEvent_GetX(self.this)
+        return val
+    def GetY(self):
+        val = windows2c.wxSplitterEvent_GetY(self.this)
+        return val
+    def GetWindowBeingRemoved(self):
+        val = windows2c.wxSplitterEvent_GetWindowBeingRemoved(self.this)
+        val = wxWindowPtr(val)
+        return val
+    def SetSashPosition(self,arg0):
+        val = windows2c.wxSplitterEvent_SetSashPosition(self.this,arg0)
+        return val
+    def __repr__(self):
+        return "<C wxSplitterEvent instance>"
+class wxSplitterEvent(wxSplitterEventPtr):
+    def __init__(self,this):
+        self.this = this
 
 
 
@@ -521,7 +574,7 @@ class wxSplitterWindow(wxSplitterWindowPtr):
         args = tuple(argl)
         self.this = apply(windows2c.new_wxSplitterWindow,(arg0.this,arg1,)+args)
         self.thisown = 1
-        wxp._StdWindowCallbacks(self)
+        wx._StdWindowCallbacks(self)
 
 
 
@@ -530,7 +583,7 @@ class wxTaskBarIconPtr(wxEvtHandlerPtr):
     def __init__(self,this):
         self.this = this
         self.thisown = 0
-    def __del__(self):
+    def __del__(self, windows2c=windows2c):
         if self.thisown == 1 :
             windows2c.delete_wxTaskBarIcon(self.this)
     def SetIcon(self,arg0,*args):
@@ -539,19 +592,22 @@ class wxTaskBarIconPtr(wxEvtHandlerPtr):
     def RemoveIcon(self):
         val = windows2c.wxTaskBarIcon_RemoveIcon(self.this)
         return val
+    def PopupMenu(self,arg0):
+        val = windows2c.wxTaskBarIcon_PopupMenu(self.this,arg0.this)
+        return val
     def __repr__(self):
         return "<C wxTaskBarIcon instance>"
 class wxTaskBarIcon(wxTaskBarIconPtr):
     def __init__(self) :
         self.this = windows2c.new_wxTaskBarIcon()
         self.thisown = 1
-        wxp._checkForCallback(self, 'OnMouseMove',    wxEVT_TASKBAR_MOVE)
-        wxp._checkForCallback(self, 'OnLButtonDown',  wxEVT_TASKBAR_LEFT_DOWN)
-        wxp._checkForCallback(self, 'OnLButtonUp',    wxEVT_TASKBAR_LEFT_UP)
-        wxp._checkForCallback(self, 'OnRButtonDown',  wxEVT_TASKBAR_RIGHT_DOWN)
-        wxp._checkForCallback(self, 'OnRButtonUp',    wxEVT_TASKBAR_RIGHT_UP)
-        wxp._checkForCallback(self, 'OnLButtonDClick',wxEVT_TASKBAR_LEFT_DCLICK)
-        wxp._checkForCallback(self, 'OnRButtonDClick',wxEVT_TASKBAR_RIGHT_DCLICK)
+        wx._checkForCallback(self, 'OnMouseMove',    wxEVT_TASKBAR_MOVE)
+        wx._checkForCallback(self, 'OnLButtonDown',  wxEVT_TASKBAR_LEFT_DOWN)
+        wx._checkForCallback(self, 'OnLButtonUp',    wxEVT_TASKBAR_LEFT_UP)
+        wx._checkForCallback(self, 'OnRButtonDown',  wxEVT_TASKBAR_RIGHT_DOWN)
+        wx._checkForCallback(self, 'OnRButtonUp',    wxEVT_TASKBAR_RIGHT_UP)
+        wx._checkForCallback(self, 'OnLButtonDClick',wxEVT_TASKBAR_LEFT_DCLICK)
+        wx._checkForCallback(self, 'OnRButtonDClick',wxEVT_TASKBAR_RIGHT_DCLICK)