Philipp Hörist pushed to branch master at gajim / gajim
Commits:
0c3ed72e by Philipp Hörist at 2019-10-04T21:08:25Z
Adapt to nbxmpp carbon data changes
- - - - -
58df7d42 by Philipp Hörist at 2019-10-04T21:08:25Z
Check if Soup is available at startup
- - - - -
48cf6366 by Philipp Hörist at 2019-10-04T21:08:25Z
Update README.md
Add Soup to runtime requirements
- - - - -
3 changed files:
- README.md
- gajim/common/modules/message.py
- gajim/gajim.py
Changes:
=====================================
README.md
=====================================
@@ -12,6 +12,7 @@
- python3-css-parser
- python3-keyring
- python3-precis-i18n
+- gir1.2-soup-2.4
### Optional Runtime Requirements
=====================================
gajim/common/modules/message.py
=====================================
@@ -69,9 +69,7 @@ class Message(BaseModule):
stanza=stanza,
account=self._account))
- forwarded = properties.carbon_type is not None
- sent = properties.carbon_type == 'sent'
- if sent:
+ if properties.is_carbon_message and properties.carbon.is_sent:
# Ugly, we treat the from attr as the remote jid,
# to make that work with sent carbons we have to do this.
# TODO: Check where in Gajim and plugins we depend on that behavior
@@ -157,8 +155,8 @@ class Message(BaseModule):
'id_': properties.id,
'encrypted': False,
'additional_data': additional_data,
- 'forwarded': forwarded,
- 'sent': sent,
+ 'forwarded': properties.is_carbon_message,
+ 'sent': properties.is_carbon_message and properties.carbon.is_sent,
'fjid': fjid,
'jid': jid,
'resource': resource,
=====================================
gajim/gajim.py
=====================================
@@ -67,12 +67,16 @@ def _init_gui(gui):
def _init_gtk():
import gi
- gi.require_version('GLib', '2.0')
- gi.require_version('Gio', '2.0')
- gi.require_version('Gtk', '3.0')
- gi.require_version('Gdk', '3.0')
- gi.require_version('GObject', '2.0')
- gi.require_version('Pango', '1.0')
+ try:
+ gi.require_version('GLib', '2.0')
+ gi.require_version('Gio', '2.0')
+ gi.require_version('Gtk', '3.0')
+ gi.require_version('Gdk', '3.0')
+ gi.require_version('GObject', '2.0')
+ gi.require_version('Pango', '1.0')
+ gi.require_version('Soup', '2.4')
+ except ValueError as error:
+ sys.exit('Missing dependency: %s' % error)
from gi.repository import Gtk
gtk_ver = '%s.%s.%s' % (Gtk.get_major_version(),
View it on GitLab:
https://dev.gajim.org/gajim/gajim/compare/b8116f40028cc82b43a66331e2f0b14002319141...48cf636600d41a880fc9285d3a2b225936d998bd
--
View it on GitLab:
https://dev.gajim.org/gajim/gajim/compare/b8116f40028cc82b43a66331e2f0b14002319141...48cf636600d41a880fc9285d3a2b225936d998bd
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