aboutsummaryrefslogtreecommitdiff
path: root/lib/connection.h
diff options
context:
space:
mode:
authorAlexey Rusakov <Kitsune-Ral@users.sf.net>2022-09-11 20:25:46 +0200
committerAlexey Rusakov <Kitsune-Ral@users.sf.net>2022-09-11 20:25:46 +0200
commit6abdd5358c9c5ed89cda5bc5e50a76af423b0634 (patch)
treefc7d34ad3811b55e0cef2fb025d3ee2a1939ecfe /lib/connection.h
parentfa34778cc377ab98a0b8f3944063e426c73a3941 (diff)
downloadlibquotient-6abdd5358c9c5ed89cda5bc5e50a76af423b0634.tar.gz
libquotient-6abdd5358c9c5ed89cda5bc5e50a76af423b0634.zip
KeyVerificationEvent; KeyVerificationSession::handleEvent()
Key verification events gain their own base type and KeyVerificationSession gets a single point of entry for all kinds of incoming events. This allows to drop a pile of `incoming*` signals in Connection and a stack of options inside switchOnType in processIfVerification(). KVS::handleEvent() also makes (some) allowed state transitions a bit clearer.
Diffstat (limited to 'lib/connection.h')
-rw-r--r--lib/connection.h11
1 files changed, 3 insertions, 8 deletions
diff --git a/lib/connection.h b/lib/connection.h
index 79c23c9a..75faf370 100644
--- a/lib/connection.h
+++ b/lib/connection.h
@@ -864,15 +864,10 @@ Q_SIGNALS:
void devicesListLoaded();
#ifdef Quotient_E2EE_ENABLED
- void incomingKeyVerificationReady(const KeyVerificationReadyEvent& event);
- void incomingKeyVerificationStart(const KeyVerificationStartEvent& event);
- void incomingKeyVerificationAccept(const KeyVerificationAcceptEvent& event);
- void incomingKeyVerificationKey(const KeyVerificationKeyEvent& event);
- void incomingKeyVerificationMac(const KeyVerificationMacEvent& event);
- void incomingKeyVerificationDone(const KeyVerificationDoneEvent& event);
- void incomingKeyVerificationCancel(const KeyVerificationCancelEvent& event);
-
void newKeyVerificationSession(KeyVerificationSession* session);
+ void keyVerificationStateChanged(
+ const KeyVerificationSession* session,
+ Quotient::KeyVerificationSession::State state);
void sessionVerified(const QString& userId, const QString& deviceId);
#endif