Change names of "from" parameters since it is a reserved word.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@70081 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2011-12-22 01:22:00 +00:00
parent a47c664ec3
commit a993a8b2ed
3 changed files with 12 additions and 2 deletions

View File

@@ -44,7 +44,7 @@ def run():
c.addCppMethod('PyObject*', 'Get', '()', """\
return sipBuildResult(0, "(ii)", self->GetRow(), self->GetCol());
""",
pyArgsString="Get() -> (row, col)",
pyArgsString="() -> (row, col)",
briefDoc="Return the row and col properties as a tuple.")
c.addCppMethod('void', 'Set', '(int row=0, int col=0)', """\
self->SetRow(row);
@@ -86,7 +86,7 @@ def run():
c.addCppMethod('PyObject*', 'Get', '()', """\
return sipBuildResult(0, "(ii)", self->GetRowspan(), self->GetColspan());
""",
pyArgsString="Get() -> (rowspan, colspan)",
pyArgsString="() -> (rowspan, colspan)",
briefDoc="Return the rowspan and colspan properties as a tuple.")
c.addCppMethod('void', 'Set', '(int rowspan=0, int colspan=0)', """\
self->SetRowspan(rowspan);

View File

@@ -41,6 +41,8 @@ def run():
c.addPyMethod('GetRange', '(self)', 'return (self.GetMin(), self.GetMax())')
c.addPyMethod('SetMin', '(self, minVal)', 'self.SetRange(minVal, self.GetMax())')
c.addPyMethod('SetMax', '(self, maxVal)', 'self.SetRange(self.GetMin(), maxVal)')
c.find('SetSelection.from').name = 'from_'
c.find('SetSelection.to').name = 'to_'
tools.fixWindowClass(c)

View File

@@ -37,6 +37,14 @@ def run():
c.find('GetSelection.from').out = True
c.find('GetSelection.to').out = True
c.find('GetRange.from').name = 'from_'
c.find('GetRange.to').name = 'to_'
c.find('Remove.from').name = 'from_'
c.find('Remove.to').name = 'to_'
c.find('Replace.from').name = 'from_'
c.find('Replace.to').name = 'to_'
c.find('SetSelection.from').name = 'from_'
c.find('SetSelection.to').name = 'to_'
#-----------------------------------------------------------------