Commit graph libervia-backend/sat_frontends/quick_frontend/quick_app.py
Author SHA1 Message Date
Goffi
cf83f04af4 quick frontend (app): show an info log if avatar is not found instead of raising exception
fix 288
2019-07-20 16:03:28 +02:00
Goffi
36f87054d1 quick frontends (app): setSpecial is now called before getOrCreateWidget in mucRoomJoinedHandler:
this avoid a issue in Primitivus where the contact list selection is done
before the room is actually added to the contact list.
2019-07-14 21:19:47 +02:00
Goffi
e14e69c883 quick frontends (app, chat): disabled the 2 most verbose logs, as they are barely useful and make reading logs difficult. 2019-06-30 15:41:59 +02:00
Goffi
fc41d45039 quick frontend (app): (un)set sync state on (dis)connect:
when connected signal is received, a whole (re)connection has happened, meaning that everything is potentially out of sync (opened widget and contact lists), so host.sync is set accordingly.
It's a temporary option, as (dis)connect is a per-profile signal, and host.sync is global. Methods similar to sync workflow must be implemented on a per-profile basis.
2019-04-07 21:09:49 +02:00
Goffi
9f147f1c36 quick frontend (app): added debug logs on sync state change + refill contact lists on resync when AUTO_RESYNC is set 2019-04-07 21:06:57 +02:00
Goffi
5a90f9d407 core, quick_frontend(app): fixed connected signal handling 2019-04-07 20:55:27 +02:00
Goffi
1b312477b1 quick_frontend (app): progress callbacks handling:
in addition to listeners, a frontend can now register progression callback and errback which are called when the given progressing action is finished.
Those callbacks can be registered using registerProgressCbs or specified in actionManager.
2019-03-20 09:08:47 +01:00
Goffi
e1e00f4d86 quick frontend (app): fixed notifications ids 2019-03-20 09:08:47 +01:00
Goffi
3eeeb8040c core: added a "_debug" signal:
this signal is a generic debugging signal which can be implemented in frontends to do specific actions, like printing data dumps.
2019-03-10 18:04:01 +01:00
Goffi
93ac4db950 quick_frontend(app): fixed use of bare jid for target when getting a new message:
in newMessage handler, full jid was sometime used for target, while is should always be bare jid. Full jid is used in the messageNew method of each widget.
2019-03-10 18:02:56 +01:00
Goffi
465d9ad62e quick frontend (app): added AUTO_RESYNC attribute in QuickApp, when set (default) the resync method is called on all widgets automatically:
if AUTO_RESYNC is False, frontend must call itself the resync method.
This is useful to improve performance, resynchronising all widgets at once may be resource intensive, and it may be more efficient to resync a widget only when it is visible.
2019-03-10 18:02:42 +01:00
Goffi
fe4a6abfae quick frontend (app): new synchronisation mechanism:
on some frontend (notably on mobiles) frontend can be paused and lose synchronisation with backend, this can also happen if backend restart a connexion without resuming using stream management. To manage that, QuickApp now has a sync attribute which is True when the backend is in sync with frontend.
When synchronisation has been lost and is possible again, all widget will have their "resync" method called, which can be used to do necessary calls to update the status.
It's the responsability of each widget to then reset the "sync" attribute, once everything has been resynchronised.
2019-03-09 16:33:31 +01:00
Goffi
3f1412f677 quick frontend(app): avoid sending empty messages 2019-03-01 17:42:28 +01:00
Goffi
512ae0b91e plugin XEP-0277: blog items data are now entirely serialised before going to bridge:
So far, and for historical reasons, blog items data where serialised using a unicode: unicode dict, which was causing trouble for many types of values (timestamps, booleans, lists).
This patch changes it by serialising the whole items before going to bridge, and deserialising it when going back. This way, complex data can be used easily in items.
This impact psEvent and serItemsData* methods which are renamed transItemsData* because there are not always serialising anymore (a new argument "serialise" allows to specify it).
When editing a blog post in jp, metadata are now more easy to manipulate, specially lists like tags.
2019-02-23 18:59:00 +01:00
Goffi
687ef5b6bd quick frontend (chat): use right type in getOrCreateWidget on new message 2019-01-22 18:52:16 +01:00
Goffi
c16292b2b5 quick frontends: visible_widgets can now keep any kind of widget, new visible_quick_widgets only iters on QuickWidgets 2019-01-20 15:46:32 +01:00
Goffi
2396f623aa quick frontend (app): fixed filtering for chat state notifications 2019-01-19 23:27:59 +01:00
Goffi
8e338bf913 date update 2019-01-12 12:25:31 +01:00
Goffi
7a9ee35cfc misc: replaced all "dummy" by the more conventional and readable "__" ("_" being used for gettext) 2019-01-11 11:13:15 +01:00
Goffi
154ba0d349 quick frontend (app): create the contact list immediatly on plug
This avoid crash when contact list is used while connexion is not done yet or not possible (e.g. server unavailable).
2018-11-05 09:13:05 +01:00
Goffi
5d6321ec9f frontends (xmlui): class_map is now an arg of create function:
class_map was so far used as a global value, but in some cases, several XMLUI managers may be used (it's the case in Cagou's remote controllers plugins, template_xmlui is used to manage remotes).
This patch set class_map as a create argument, this way it can be set with partial, and several XMLUI managers can be instanced at the same time.
2018-08-31 16:03:12 +02:00
Goffi
1cb7461f99 quick frontend (app, chat): encryption handling:
- new QuickApp.ENCRYPTION_HANDLERS class attribute, if True (default), encryption handlers are set
- encryption plugins are retrieved on startup and cached in QuickApp.encryption_plugins list
- QuickChat's encrypted boolean attribute indicate if a session is currently encrypted. This is updated
  automatically if ENCRYPTION_HANDLERS is set
- if ENCRYPTION_HANDLERS is set, messageEncryptionStarted and messageEncryptionStopped are called when
  suitable.
2018-08-11 18:24:55 +02:00
Goffi
1a74cdce28 quick_frontend (QuickApp): fixed getCache handling after changes in QuickContactList 2018-06-27 22:50:32 +02:00
Goffi
744cb0c503 code style reformatting using black 2018-06-27 20:14:46 +02:00
Goffi
cf0d3af803 quick app: added missing docstring in showDialog 2018-06-26 07:09:49 +02:00
Goffi
212b4fe88a quick frontends (app): retrieve namespaces on startup 2018-05-22 10:07:33 +02:00
Goffi
a6956d424a quick frontend (app): avoid resource locking on new message 2018-05-11 20:06:06 +02:00
Goffi
bc83869090 quick frontend (contact list): don't store "nick" for group contacts:
plugin XEP-0054 may associate a "nick" with a bare jid, which in case of MUC can cause trouble (Primitivus for instance will use the nick instead of the name of the room).
This hack avoid this issue for now.
2018-05-11 17:13:58 +02:00
Goffi
80ef13612b core, setup: huge cleaning:
- moved directories from src and frontends/src to sat and sat_frontends, which is the recommanded naming convention
- move twisted directory to root
- removed all hacks from setup.py, and added missing dependencies, it is now clean
- use https URL for website in setup.py
- removed "Environment :: X11 Applications :: GTK", as wix is deprecated and removed
- renamed sat.sh to sat and fixed its installation
- added python_requires to specify Python version needed
- replaced glib2reactor which use deprecated code by gtk3reactor

sat can now be installed directly from virtualenv without using --system-site-packages anymore \o/
2018-04-02 19:44:50 +02:00
Renamed from frontends/src/quick_frontend/quick_app.py (Browse further)