Merge pull request #301 from prculley/bug8128_pm

bug 9856; fix popup ProgressMonitor to find a parent for set_transient_for
This commit is contained in:
Paul Franklin 2016-12-27 11:48:35 -08:00 committed by GitHub
commit 0496756abb

View File

@ -496,6 +496,11 @@ class GtkProgressDialog(Gtk.Dialog):
Gtk.Dialog.__init__(self)
if len(window_params) >= 2:
self.set_transient_for(window_params[1])
else:
for win in Gtk.Window.list_toplevels():
if win.is_active():
self.set_transient_for(win)
break
if len(window_params) >= 3:
flags = window_params[2]
if Gtk.DialogFlags.MODAL & flags: