bpo-37177: make IDLE's search dialogs transient (GH-13869)

This avoids the search dialogs being hidden behind the editor window.
This commit is contained in:
Tal Einat 2019-06-07 08:54:40 +03:00 committed by GitHub
parent de76c07a8c
commit 554450fb4e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 5 deletions

View file

@ -54,6 +54,7 @@ class SearchDialogBase:
else:
self.top.deiconify()
self.top.tkraise()
self.top.transient(text.winfo_toplevel())
if searchphrase:
self.ent.delete(0,"end")
self.ent.insert("end",searchphrase)
@ -66,6 +67,7 @@ class SearchDialogBase:
"Put dialog away for later use."
if self.top:
self.top.grab_release()
self.top.transient('')
self.top.withdraw()
def create_widgets(self):