summaryrefslogtreecommitdiffstats
path: root/Lib/lib-tk
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1998-10-12 20:40:47 (GMT)
committerGuido van Rossum <guido@python.org>1998-10-12 20:40:47 (GMT)
commit3179b36014d1dd48cc3f1363edf4b1adecc12c79 (patch)
tree9b9dd27889b4dc234000dd499cc61274dcd07c3c /Lib/lib-tk
parent7f20263349abf23608fc87aa801a5db72125bfec (diff)
downloadcpython-3179b36014d1dd48cc3f1363edf4b1adecc12c79.zip
cpython-3179b36014d1dd48cc3f1363edf4b1adecc12c79.tar.gz
cpython-3179b36014d1dd48cc3f1363edf4b1adecc12c79.tar.bz2
When no master widget is specified, use options['parent'] if it exists.
Diffstat (limited to 'Lib/lib-tk')
-rw-r--r--Lib/lib-tk/tkCommonDialog.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/lib-tk/tkCommonDialog.py b/Lib/lib-tk/tkCommonDialog.py
index c63ca11..55cf064 100644
--- a/Lib/lib-tk/tkCommonDialog.py
+++ b/Lib/lib-tk/tkCommonDialog.py
@@ -27,6 +27,8 @@ class Dialog:
self.master = master
self.options = options
+ if not master and options.get('parent'):
+ self.master = options['parent']
def _fixoptions(self):
pass # hook