SynchroniseSelectAccountDialog, ClientCertChooserDialog set transient_for. See #7185
This commit is contained in:
parent
b0bc896aca
commit
c9bddaf1cf
|
@ -1477,9 +1477,10 @@ class FileChooserDialog(Gtk.FileChooserDialog):
|
||||||
"""
|
"""
|
||||||
def __init__(self, title_text, action, buttons, default_response,
|
def __init__(self, title_text, action, buttons, default_response,
|
||||||
select_multiple=False, current_folder=None, on_response_ok=None,
|
select_multiple=False, current_folder=None, on_response_ok=None,
|
||||||
on_response_cancel=None):
|
on_response_cancel=None, transient_for=None):
|
||||||
|
|
||||||
GObject.GObject.__init__(self, title=title_text, action=action)
|
GObject.GObject.__init__(self, title=title_text, parent=transient_for,
|
||||||
|
action=action)
|
||||||
self.add_button(buttons[0],buttons[1])
|
self.add_button(buttons[0],buttons[1])
|
||||||
if len(buttons) ==4:
|
if len(buttons) ==4:
|
||||||
self.add_button(buttons[2],buttons[3])
|
self.add_button(buttons[2],buttons[3])
|
||||||
|
@ -2695,6 +2696,7 @@ class SynchroniseSelectAccountDialog:
|
||||||
self.account = account
|
self.account = account
|
||||||
self.xml = gtkgui_helpers.get_gtk_builder('synchronise_select_account_dialog.ui')
|
self.xml = gtkgui_helpers.get_gtk_builder('synchronise_select_account_dialog.ui')
|
||||||
self.dialog = self.xml.get_object('synchronise_select_account_dialog')
|
self.dialog = self.xml.get_object('synchronise_select_account_dialog')
|
||||||
|
self.dialog.set_transient_for(gajim.interface.instances['accounts'].window)
|
||||||
self.accounts_treeview = self.xml.get_object('accounts_treeview')
|
self.accounts_treeview = self.xml.get_object('accounts_treeview')
|
||||||
model = Gtk.ListStore(str, str, bool)
|
model = Gtk.ListStore(str, str, bool)
|
||||||
self.accounts_treeview.set_model(model)
|
self.accounts_treeview.set_model(model)
|
||||||
|
@ -4709,6 +4711,7 @@ class ClientCertChooserDialog(FileChooserDialog):
|
||||||
|
|
||||||
FileChooserDialog.__init__(self,
|
FileChooserDialog.__init__(self,
|
||||||
title_text=_('Choose Client Cert #PCKS12'),
|
title_text=_('Choose Client Cert #PCKS12'),
|
||||||
|
transient_for=gajim.interface.instances['accounts'].window,
|
||||||
action=Gtk.FileChooserAction.OPEN,
|
action=Gtk.FileChooserAction.OPEN,
|
||||||
buttons=(Gtk.STOCK_CANCEL, Gtk.ResponseType.CANCEL,
|
buttons=(Gtk.STOCK_CANCEL, Gtk.ResponseType.CANCEL,
|
||||||
Gtk.STOCK_OPEN, Gtk.ResponseType.OK),
|
Gtk.STOCK_OPEN, Gtk.ResponseType.OK),
|
||||||
|
|
Loading…
Reference in New Issue