diff --git a/docs/sphinx/rest_substitutions/snippets/python/converted/wx.BusyCursor.1.py b/docs/sphinx/rest_substitutions/snippets/python/converted/wx.BusyCursor.1.py index 181f59d2..0254dbcd 100644 --- a/docs/sphinx/rest_substitutions/snippets/python/converted/wx.BusyCursor.1.py +++ b/docs/sphinx/rest_substitutions/snippets/python/converted/wx.BusyCursor.1.py @@ -1,7 +1,11 @@ + # Normal usage wait = wx.BusyCursor() - - for i in xrange(10000): + for i in range(10000): DoACalculation() - del wait + + # It can be used as a context manager too + with wx.BusyCursor(): + for i in range(10000): + DoACalculation()