From e4ed5de1fe1001ee56d7edcadc839e2db1831e77 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Fri, 21 Jun 2002 02:04:43 +0000 Subject: [PATCH] fixed a typo git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15903 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- wxPython/src/controls2.i | 6 +++--- wxPython/src/msw/controls2.py | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/wxPython/src/controls2.i b/wxPython/src/controls2.i index 31acadfa5e..92c8fe6010 100644 --- a/wxPython/src/controls2.i +++ b/wxPython/src/controls2.i @@ -449,9 +449,9 @@ public: else return NULL; } - } // The OOR typemaps don't know what to do with the %new, so fix it up. + } // The OOR typemaps don't know what to do with the %new, so fix it up. %pragma(python) addtoclass = " - def GetItem(self, *_args, **_kwargs): + def GetColumn(self, *_args, **_kwargs): val = apply(controls2c.wxListCtrl_GetColumn,(self,) + _args, _kwargs) if val is not None: val.thisown = 1 return val @@ -492,7 +492,7 @@ public: %pragma(python) addtoclass = " def GetItem(self, *_args, **_kwargs): val = apply(controls2c.wxListCtrl_GetItem,(self,) + _args, _kwargs) - val.thisown = 1 + if val is not None: val.thisown = 1 return val " diff --git a/wxPython/src/msw/controls2.py b/wxPython/src/msw/controls2.py index 4e0d8638e8..fe8aade9d1 100644 --- a/wxPython/src/msw/controls2.py +++ b/wxPython/src/msw/controls2.py @@ -637,7 +637,7 @@ class wxListCtrlPtr(wxControlPtr): def __repr__(self): return "" % (self.this,) - def GetItem(self, *_args, **_kwargs): + def GetColumn(self, *_args, **_kwargs): val = apply(controls2c.wxListCtrl_GetColumn,(self,) + _args, _kwargs) if val is not None: val.thisown = 1 return val @@ -645,7 +645,7 @@ class wxListCtrlPtr(wxControlPtr): def GetItem(self, *_args, **_kwargs): val = apply(controls2c.wxListCtrl_GetItem,(self,) + _args, _kwargs) - val.thisown = 1 + if val is not None: val.thisown = 1 return val -- 2.47.2