From 751d1f5b77651c27f7ec8494538e8163ae81a4d6 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Wed, 18 Dec 2002 06:25:03 +0000 Subject: [PATCH] Fixes for Python 2.1 compatibility git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@18320 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- wxPython/demo/Throbber.py | 6 +++--- wxPython/wxPython/lib/popupctl.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/wxPython/demo/Throbber.py b/wxPython/demo/Throbber.py index b80c776235..84725cef8f 100644 --- a/wxPython/demo/Throbber.py +++ b/wxPython/demo/Throbber.py @@ -118,7 +118,7 @@ class TestPanel(wxPanel): sizer.SetSizeHints(self) sizer.Fit(self) - for t in self.throbbers: + for t in self.throbbers.keys(): self.throbbers[t]['throbber'].Start() self.otherThrobber.Start() self.otherThrobber.Reverse() @@ -130,11 +130,11 @@ class TestPanel(wxPanel): event.Skip() def OnStartAnimation(self, event): - for t in self.throbbers: + for t in self.throbbers.keys(): self.throbbers[t]['throbber'].Start() def OnStopAnimation(self, event): - for t in self.throbbers: + for t in self.throbbers.keys(): self.throbbers[t]['throbber'].Rest() def OnClickThrobber(self, event): diff --git a/wxPython/wxPython/lib/popupctl.py b/wxPython/wxPython/lib/popupctl.py index fe4408a9b3..34568d65d8 100644 --- a/wxPython/wxPython/lib/popupctl.py +++ b/wxPython/wxPython/lib/popupctl.py @@ -185,7 +185,7 @@ class wxPopupDialog(wxDialog): class wxPopupControl(wxPyControl): def __init__(self,*_args,**_kwargs): - if 'value' in _kwargs: + if _kwargs.has_key('value'): del _kwargs['value'] apply(wxPyControl.__init__,(self,) + _args,_kwargs)