summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin v. Löwis <martin@v.loewis.de>2006-07-03 09:44:00 (GMT)
committerMartin v. Löwis <martin@v.loewis.de>2006-07-03 09:44:00 (GMT)
commitbd39c03c9faabcad9d6966c7e1a282e38823f456 (patch)
treed1b669aba54b696e2f4766ac008b4b578afbbc8e
parent16a393277410f38d9fa4a67d86433f1e3641f142 (diff)
downloadcpython-bd39c03c9faabcad9d6966c7e1a282e38823f456.zip
cpython-bd39c03c9faabcad9d6966c7e1a282e38823f456.tar.gz
cpython-bd39c03c9faabcad9d6966c7e1a282e38823f456.tar.bz2
Only setup canvas when it is first created.
Fixes #1514703
-rw-r--r--Lib/lib-tk/turtle.py2
-rw-r--r--Misc/NEWS3
2 files changed, 4 insertions, 1 deletions
diff --git a/Lib/lib-tk/turtle.py b/Lib/lib-tk/turtle.py
index 0fe83a3..b5bad59 100644
--- a/Lib/lib-tk/turtle.py
+++ b/Lib/lib-tk/turtle.py
@@ -679,7 +679,7 @@ class Pen(RawPen):
_canvas = Tkinter.Canvas(_root, background="white")
_canvas.pack(expand=1, fill="both")
- setup(width=_width, height= _height, startx=_startx, starty=_starty)
+ setup(width=_width, height= _height, startx=_startx, starty=_starty)
RawPen.__init__(self, _canvas)
diff --git a/Misc/NEWS b/Misc/NEWS
index a6b4c2e..63e4b75 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -19,6 +19,9 @@ Core and builtins
Library
-------
+- Bug #1514703: Only setup canvas window in turtle when the canvas
+ is created.
+
- Bug #1513223: .close() of a _socketobj now releases the underlying
socket again, which then gets closed as it becomes unreferenced.