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

This avoids the search dialogs being hidden behind the editor window.
(cherry picked from commit 554450fb4e)

Co-authored-by: Tal Einat <taleinat@gmail.com>
This commit is contained in:
Miss Islington (bot) 2019-06-06 23:17:13 -07:00 committed by GitHub
parent dba4448c63
commit 295fe32e39
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):