GpgFrontend Project
A Free, Powerful, Easy-to-Use, Compact, Cross-Platform, and Installation-Free OpenPGP(pgp) Crypto Tool.
KeyPairSubkeyTab.h
1 
29 #pragma once
30 
31 #include "KeySetExpireDateDialog.h"
32 #include "core/function/gpg/GpgContext.h"
33 #include "ui/GpgFrontendUI.h"
34 #include "ui/dialog/key_generate/SubkeyGenerateDialog.h"
35 
36 namespace GpgFrontend::UI {
37 
38 class KeyPairSubkeyTab : public QWidget {
39  Q_OBJECT
40 
41  public:
48  KeyPairSubkeyTab(const QString& key, QWidget* parent);
49 
50  private:
55  void create_subkey_list();
56 
62 
69 
70  GpgKey key_;
71  QTableWidget* subkey_list_{};
72  std::vector<GpgSubKey> buffered_subkeys_;
73 
74  QGroupBox* list_box_;
75  QGroupBox* detail_box_;
76 
77  QMenu* subkey_opera_menu_{};
78 
83  QLabel* algorithm_detail_var_label_;
86  QLabel* usage_var_label_;
87  QLabel* master_key_exist_var_label_;
88  QLabel* card_key_label_;
89 
90  private slots:
91 
96  void slot_add_subkey();
97 
102  void slot_refresh_subkey_list();
103 
108  void slot_refresh_subkey_detail();
109 
114  void slot_edit_subkey();
115 
120  void slot_revoke_subkey();
121 
126  void slot_refresh_key_info();
127 
128  protected:
134  void contextMenuEvent(QContextMenuEvent* event) override;
135 };
136 
137 } // namespace GpgFrontend::UI
Definition: GpgKey.h:40
Definition: GpgSubKey.h:41
Definition: KeyPairSubkeyTab.h:38
void create_subkey_list()
Create a subkey list object.
Definition: KeyPairSubkeyTab.cpp:140
QLabel * fingerprint_var_label_
Label containing the keys fingerprint.
Definition: KeyPairSubkeyTab.h:85
QLabel * algorithm_var_label_
Label containing the keys algorithm.
Definition: KeyPairSubkeyTab.h:82
QLabel * key_id_var_label_
Label containing the keys keyid.
Definition: KeyPairSubkeyTab.h:84
void create_subkey_opera_menu()
Create a subkey opera menu object.
Definition: KeyPairSubkeyTab.cpp:302
QLabel * key_size_var_label_
Label containing the keys key size.
Definition: KeyPairSubkeyTab.h:79
QLabel * expire_var_label_
Label containing the keys expiration date.
Definition: KeyPairSubkeyTab.h:80
KeyPairSubkeyTab(const QString &key, QWidget *parent)
Construct a new Key Pair Subkey Tab object.
Definition: KeyPairSubkeyTab.cpp:38
const GpgSubKey & get_selected_subkey()
Get the selected subkey object.
Definition: KeyPairSubkeyTab.cpp:327
QLabel * created_var_label_
Label containing the keys creation date.
Definition: KeyPairSubkeyTab.h:81
void contextMenuEvent(QContextMenuEvent *event) override
Definition: KeyPairSubkeyTab.cpp:321
Definition: FileReadTask.cpp:31