From f990d02235173f2c8caa96e5f6007dc1562e10f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20Knau=C3=9F?= Date: Thu, 17 Nov 2016 14:19:16 +0100 Subject: check errorType for errors from gpgme --- framework/domain/mimetreeparser/interface.h | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) (limited to 'framework/domain/mimetreeparser/interface.h') diff --git a/framework/domain/mimetreeparser/interface.h b/framework/domain/mimetreeparser/interface.h index 1c6fd31d..7c3ea28b 100644 --- a/framework/domain/mimetreeparser/interface.h +++ b/framework/domain/mimetreeparser/interface.h @@ -255,18 +255,6 @@ private: friend class SinglePartPrivate; }; - -class EncryptionPart : public Part -{ -public: - typedef std::shared_ptr Ptr; - QByteArray type() const Q_DECL_OVERRIDE; - - EncryptionError error() const; -private: - std::unique_ptr d; -}; - /* * we want to request complete headers like: * from/to... @@ -344,11 +332,19 @@ public: class Encryption { public: + enum ErrorType { + NoError, + PassphraseError, + KeyMissing, + UnknownError + }; typedef std::shared_ptr Ptr; Encryption(); Encryption(EncryptionPrivate *); ~Encryption(); std::vector recipients() const; + QString errorString(); + ErrorType errorType(); private: std::unique_ptr d; }; -- cgit v1.2.3