PIVX Core  5.6.99
P2P Digital Currency
lockunlock.h
Go to the documentation of this file.
1 // Copyright (c) 2019 The PIVX Core developers
2 // Distributed under the MIT software license, see the accompanying
3 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
4 
5 #ifndef PIVX_QT_LOCKUNLOCK_H
6 #define PIVX_QT_LOCKUNLOCK_H
7 
8 #include <QWidget>
9 #include "walletmodel.h"
10 
11 namespace Ui {
12 class LockUnlock;
13 }
14 
17 };
18 
19 
20 class LockUnlock : public QWidget
21 {
22  Q_OBJECT
23 
24 public:
25  explicit LockUnlock(QWidget *parent = nullptr);
26  ~LockUnlock();
28  int lock = 0;
29  bool isHovered();
30 Q_SIGNALS:
31  void Mouse_Entered();
32  void Mouse_Leave();
33 
34  void lockClicked(const StateClicked& state);
35 protected:
36  virtual void enterEvent(QEvent *);
37  virtual void leaveEvent(QEvent *);
38 
39 public Q_SLOTS:
40  void onLockClicked();
41  void onUnlockClicked();
42  void onStakingClicked();
43 
44 private:
45  Ui::LockUnlock *ui;
46  bool isOnHover = false;
47 };
48 
49 #endif // PIVX_QT_LOCKUNLOCK_H
void lockClicked(const StateClicked &state)
Ui::LockUnlock * ui
Definition: lockunlock.h:45
bool isOnHover
Definition: lockunlock.h:46
void Mouse_Entered()
void onLockClicked()
Definition: lockunlock.cpp:60
virtual void enterEvent(QEvent *)
Definition: lockunlock.cpp:78
void Mouse_Leave()
void onStakingClicked()
Definition: lockunlock.cpp:72
virtual void leaveEvent(QEvent *)
Definition: lockunlock.cpp:84
void onUnlockClicked()
Definition: lockunlock.cpp:66
void updateStatus(WalletModel::EncryptionStatus status)
Definition: lockunlock.cpp:37
LockUnlock(QWidget *parent=nullptr)
Definition: lockunlock.cpp:8
bool isHovered()
Definition: lockunlock.cpp:90
StateClicked
Definition: lockunlock.h:15
@ UNLOCK
Definition: lockunlock.h:16
@ LOCK
Definition: lockunlock.h:16
@ UNLOCK_FOR_STAKING
Definition: lockunlock.h:16