diff --git a/plugins/gtkgui/dialogs.py b/plugins/gtkgui/dialogs.py index 2c3eb5c46..56ff4b54f 100644 --- a/plugins/gtkgui/dialogs.py +++ b/plugins/gtkgui/dialogs.py @@ -372,6 +372,8 @@ class addContact_Window: end_iter = buf.get_end_iter() txt = buf.get_text(start_iter, end_iter, 0) self.plugin.roster.req_sub(self, who, txt, self.account, pseudo) + if self.xml.get_widget('checkbutton_auth').get_active(): + self.plugin.send('AUTH', self.account, who) widget.get_toplevel().destroy() def fill_who(self): @@ -450,6 +452,10 @@ class addContact_Window: self.fill_who() if jid: self.xml.get_widget('entry_who').set_text(jid) + jida = jid.split("@") + self.xml.get_widget('entry_login').set_text(jida[0]) + if jida[1] in jid_agents: + cb.set_active(jid_agents.index(jida[1])+1) self.xml.signal_connect('gtk_widget_destroy', self.delete_event) self.xml.signal_connect('on_button_sub_clicked', self.on_subscribe) self.xml.signal_connect('on_cancel_clicked', self.on_cancel) diff --git a/plugins/gtkgui/gtkgui.glade b/plugins/gtkgui/gtkgui.glade index e6ca74ef9..4fc64478c 100644 --- a/plugins/gtkgui/gtkgui.glade +++ b/plugins/gtkgui/gtkgui.glade @@ -2150,6 +2150,8 @@ on the server. 5 + 400 + 270 True Add user GTK_WINDOW_TOPLEVEL @@ -2172,7 +2174,7 @@ on the server. True - 4 + 5 3 False 5 @@ -2373,6 +2375,28 @@ on the server. + + + + True + True + Automatically authorize contact + True + GTK_RELIEF_NORMAL + True + True + False + True + + + 1 + 3 + 4 + 5 + fill + + + 10