aboutsummaryrefslogtreecommitdiff
path: root/libdino/src/service/file_manager.vala
diff options
context:
space:
mode:
authorkmq <kmq@users.noreply.github.com>2020-04-18 15:18:25 +0000
committerGitHub <noreply@github.com>2020-04-18 17:18:25 +0200
commit2419bf3b15758abfde7ac2eea52c5b791adfdf59 (patch)
tree085d00034819262f4cb88eb1306b259a05679a07 /libdino/src/service/file_manager.vala
parentfcad6720e66318f99940aca6b145fc50e90d29e2 (diff)
downloaddino-2419bf3b15758abfde7ac2eea52c5b791adfdf59.tar.gz
dino-2419bf3b15758abfde7ac2eea52c5b791adfdf59.zip
Update last_activity before received_file signal to keep UI in sync (#811)
Fixes #791 where a signal to update the UI is sent to late when sending files, resulting in an out of sync conversations list.
Diffstat (limited to 'libdino/src/service/file_manager.vala')
-rw-r--r--libdino/src/service/file_manager.vala2
1 files changed, 1 insertions, 1 deletions
diff --git a/libdino/src/service/file_manager.vala b/libdino/src/service/file_manager.vala
index 54579a04..20540e6e 100644
--- a/libdino/src/service/file_manager.vala
+++ b/libdino/src/service/file_manager.vala
@@ -63,6 +63,7 @@ public class FileManager : StreamInteractionModule, Object {
yield save_file(file_transfer);
file_transfer.persist(db);
+ conversation.last_active = file_transfer.time;
received_file(file_transfer, conversation);
} catch (Error e) {
file_transfer.state = FileTransfer.State.FAILED;
@@ -113,7 +114,6 @@ public class FileManager : StreamInteractionModule, Object {
yield file_sender.send_file(conversation, file_transfer, file_send_data, file_meta);
- conversation.last_active = file_transfer.time;
} catch (Error e) {
warning("Send file error: %s", e.message);
file_transfer.state = FileTransfer.State.FAILED;