Philipp Hörist pushed to branch master at gajim / gajim
Commits:
a3d17c6d by Philipp Hörist at 2022-10-27T22:40:32+02:00
fix: StartChat: Don’t use jid argument for global dialog
The jid attribute indicates that this is a dialog which can be
opened per jid, which we dont want here.
- - - - -
2 changed files:
- gajim/gtk/application.py
- gajim/gtk/start_chat.py
Changes:
=====================================
gajim/gtk/application.py
=====================================
@@ -630,7 +630,7 @@ def _on_new_chat_action(_action: Gio.SimpleAction,
jid, initial_message = param.get_strv()
open_window('StartChatDialog',
- jid=jid or None,
+ initial_jid=jid or None,
initial_message=initial_message or None)
@staticmethod
@@ -740,7 +740,7 @@ def _on_join_support_chat(_action: Gio.SimpleAction,
app.interface.show_add_join_groupchat(
accounts[0], GAJIM_SUPPORT_JID)
return
- open_window('StartChatDialog', jid=GAJIM_SUPPORT_JID)
+ open_window('StartChatDialog', initial_jid=GAJIM_SUPPORT_JID)
@staticmethod
def _on_faq_action(_action: Gio.SimpleAction,
=====================================
gajim/gtk/start_chat.py
=====================================
@@ -69,7 +69,7 @@ class Search(IntEnum):
class StartChatDialog(Gtk.ApplicationWindow):
def __init__(self,
- jid: Optional[str] = None,
+ initial_jid: Optional[str] = None,
initial_message: Optional[str] = None
) -> None:
@@ -143,9 +143,9 @@ def __init__(self,
self._load_contacts(rows)
self._initial_message: dict[str, Optional[str]] = {}
- if jid is not None:
- self._initial_message[jid] = initial_message
- self._ui.search_entry.set_text(jid)
+ if initial_jid is not None:
+ self._initial_message[initial_jid] = initial_message
+ self._ui.search_entry.set_text(initial_jid)
self.select_first_row()
self._ui.connect_signals(self)
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/a3d17c6d23b936aed077ce9a6335011500b27445
--
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/a3d17c6d23b936aed077ce9a6335011500b27445
You're receiving this email because of your account on dev.gajim.org.
_______________________________________________
Commits mailing list
[email protected]
https://lists.gajim.org/cgi-bin/listinfo/commits