Philipp Hörist pushed to branch master at gajim / gajim
Commits:
1f47544f by mesonium at 2024-11-29T22:17:13+00:00
refactor: Port away from deprecated method
- - - - -
2 changed files:
- gajim/gtk/application.py
- gajim/gtk/notification.py
Changes:
=====================================
gajim/gtk/application.py
=====================================
@@ -36,7 +36,6 @@
from datetime import timezone
from urllib.parse import unquote
-from gi.repository import Gdk
from gi.repository import Gio
from gi.repository import GLib
from gi.repository import Gtk
@@ -803,7 +802,7 @@ def _on_open_event_action(
jid = JID.from_string(params.jid)
app.window.select_chat(params.account, jid)
- app.window.present_with_time(Gdk.CURRENT_TIME)
+ app.window.present()
@structs.actionmethod
def _on_mark_as_read_action(
=====================================
gajim/gtk/notification.py
=====================================
@@ -214,7 +214,7 @@ def _on_activated(self, event: ToastActivatedEventArgs) ->
None:
# Calls need to be executed with GLib.idle_add to avoid threading
issues,
# because Toasts run in a different thread.
if event.arguments is None:
- GLib.idle_add(app.window.present_with_time, Gdk.CURRENT_TIME)
+ GLib.idle_add(app.window.present)
return
if event.arguments.startswith("open-event-"):
@@ -243,7 +243,7 @@ def _on_activated(self, event: ToastActivatedEventArgs) ->
None:
)
return
- GLib.idle_add(app.window.present_with_time, Gdk.CURRENT_TIME)
+ GLib.idle_add(app.window.present)
def _get_toast_image(self, event: events.Notification) -> ToastImage:
if event.type == "incoming-message":
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/1f47544f2b7acebae5af977bce43ccff2762fed8
--
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/1f47544f2b7acebae5af977bce43ccff2762fed8
You're receiving this email because of your account on dev.gajim.org.
_______________________________________________
Commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]