From 4c48bdc07291f55d7320721a5b0a29c092f7daa0 Mon Sep 17 00:00:00 2001 From: Marvin W Date: Sat, 11 Mar 2017 01:25:45 +0100 Subject: Improve Plugin API (allow to move encryption into plugin) --- libdino/src/entity/conversation.vala | 7 +------ libdino/src/entity/encryption.vala | 9 +++++++++ libdino/src/entity/message.vala | 5 ----- 3 files changed, 10 insertions(+), 11 deletions(-) create mode 100644 libdino/src/entity/encryption.vala (limited to 'libdino/src/entity') diff --git a/libdino/src/entity/conversation.vala b/libdino/src/entity/conversation.vala index 2da6dce3..5a83e02b 100644 --- a/libdino/src/entity/conversation.vala +++ b/libdino/src/entity/conversation.vala @@ -3,11 +3,6 @@ public class Conversation : Object { public signal void object_updated(Conversation conversation); - public enum Encryption { - UNENCRYPTED, - PGP - } - public enum Type { CHAT, GROUPCHAT @@ -27,7 +22,7 @@ public class Conversation : Object { this.account = account; this.active = false; this.last_active = new DateTime.from_unix_utc(0); - this.encryption = Encryption.UNENCRYPTED; + this.encryption = Encryption.NONE; } public Conversation.with_id(Jid jid, Account account, int id) { diff --git a/libdino/src/entity/encryption.vala b/libdino/src/entity/encryption.vala new file mode 100644 index 00000000..b50556f9 --- /dev/null +++ b/libdino/src/entity/encryption.vala @@ -0,0 +1,9 @@ +namespace Dino.Entities { + +public enum Encryption { + NONE, + PGP, + OMEMO +} + +} \ No newline at end of file diff --git a/libdino/src/entity/message.vala b/libdino/src/entity/message.vala index 65d05bdf..16562561 100644 --- a/libdino/src/entity/message.vala +++ b/libdino/src/entity/message.vala @@ -16,11 +16,6 @@ public class Dino.Entities.Message : Object { WONTSEND } - public enum Encryption { - NONE, - PGP - } - public enum Type { ERROR, CHAT, -- cgit v1.2.3-70-g09d2