summaryrefslogtreecommitdiff
path: root/src/pincodemanager.h
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2018-03-07 23:32:25 +0300
committerAndrei Karas <akaras@inbox.ru>2018-03-07 23:32:25 +0300
commit0d9e625499c18a4eaf79d38dfb1ef6abf0c553bd (patch)
tree1e4c29a0de3697946060410e41910f88bcc5b979 /src/pincodemanager.h
parentb6cd136e3edf9d5c0eaaef47118ff1a72d7b0c75 (diff)
downloadplus-0d9e625499c18a4eaf79d38dfb1ef6abf0c553bd.tar.gz
plus-0d9e625499c18a4eaf79d38dfb1ef6abf0c553bd.tar.bz2
plus-0d9e625499c18a4eaf79d38dfb1ef6abf0c553bd.tar.xz
plus-0d9e625499c18a4eaf79d38dfb1ef6abf0c553bd.zip
Add support for set new pincode.
Add pincode dialog and widget.
Diffstat (limited to 'src/pincodemanager.h')
-rw-r--r--src/pincodemanager.h25
1 files changed, 19 insertions, 6 deletions
diff --git a/src/pincodemanager.h b/src/pincodemanager.h
index 58af704ed..bf3d2e8fc 100644
--- a/src/pincodemanager.h
+++ b/src/pincodemanager.h
@@ -23,8 +23,15 @@
#include "enums/simpletypes/beingid.h"
+#include "enums/gui/pincodestate.h"
+
+#include <string>
+
#include "localconsts.h"
+class PincodeDialog;
+class Window;
+
class PincodeManager final
{
public:
@@ -36,13 +43,9 @@ class PincodeManager final
void init();
- void pinOk();
-
- void askPin();
+ void updateState();
- void createNewPin();
-
- void changePin();
+ void pinOk();
void wrongPin();
@@ -52,9 +55,19 @@ class PincodeManager final
void setAccountId(const BeingId id)
{ mAccountId = id; }
+ void setState(const PincodeState state)
+ { mState = state; }
+
+ void clearDialog(const PincodeDialog *const PincodeDialog);
+
+ void setNewPincode(const std::string &pincode);
+
protected:
+ std::string mNewPincode;
uint32_t mSeed;
BeingId mAccountId;
+ Window *mDialog;
+ PincodeState mState;
};
extern PincodeManager pincodeManager;