KeyPairSubkeyTab.h
#ifndef GPGFRONTEND_KEYPAIRSUBKEYTAB_H
#define GPGFRONTEND_KEYPAIRSUBKEYTAB_H
#include "KeySetExpireDateDialog.h"
#include "core/GpgContext.h"
#include "ui/GpgFrontendUI.h"
#include "ui/dialog/key_generate/SubkeyGenerateDialog.h"
namespace GpgFrontend::UI {
class KeyPairSubkeyTab : public QWidget {
Q_OBJECT
public:
KeyPairSubkeyTab(const std::string& key, QWidget* parent);
private:
void create_subkey_list();
void create_subkey_opera_menu();
const GpgSubKey& get_selected_subkey();
GpgKey key_;
QTableWidget* subkey_list_{};
std::vector<GpgSubKey> buffered_subkeys_;
QGroupBox* list_box_;
QGroupBox* detail_box_;
QMenu* subkey_opera_menu_{};
QLabel* key_size_var_label_;
QLabel* expire_var_label_;
QLabel* created_var_label_;
QLabel* algorithm_var_label_;
QLabel* key_id_var_label_;
QLabel* fingerprint_var_label_;
QLabel* usage_var_label_;
QLabel* master_key_exist_var_label_;
QLabel* card_key_label_;
private slots:
void slot_add_subkey();
void slot_refresh_subkey_list();
void slot_refresh_subkey_detail();
void slot_edit_subkey();
void slot_revoke_subkey();
void slot_refresh_key_info();
protected:
void contextMenuEvent(QContextMenuEvent* event) override;
};
} // namespace GpgFrontend::UI
#endif // GPGFRONTEND_KEYPAIRSUBKEYTAB_H
GpgFrontend::UI::KeyPairSubkeyTab::contextMenuEvent
void contextMenuEvent(QContextMenuEvent *event) override
Definition: KeyPairSubkeyTab.cpp:318
GpgFrontend::UI::KeyPairSubkeyTab::expire_var_label_
QLabel * expire_var_label_
Label containing the keys expiration date.
Definition: KeyPairSubkeyTab.h:81
GpgFrontend::UI
Definition: FileReadTask.cpp:31
GpgFrontend::UI::KeySetExpireDateDialog
Definition: KeySetExpireDateDialog.h:42
GpgFrontend::GpgKey::GetId
std::string GetId() const
Definition: GpgKey.cpp:52
GpgFrontend::SingletonFunctionObject< GpgKeyGetter >::GetInstance
static GpgKeyGetter & GetInstance(int channel=GpgFrontend::GPGFRONTEND_DEFAULT_CHANNEL)
Get the Instance object.
Definition: GpgFunctionObject.h:170
GpgFrontend::UI::KeyPairSubkeyTab::created_var_label_
QLabel * created_var_label_
Label containing the keys creation date.
Definition: KeyPairSubkeyTab.h:82
GpgFrontend::UI::KeyPairSubkeyTab::key_id_var_label_
QLabel * key_id_var_label_
Label containing the keys keyid.
Definition: KeyPairSubkeyTab.h:84
GpgFrontend::GpgKeyGetter
Definition: GpgKeyGetter.h:45
GpgFrontend::UI::KeyPairSubkeyTab::create_subkey_opera_menu
void create_subkey_opera_menu()
Create a subkey opera menu object.
Definition: KeyPairSubkeyTab.cpp:299
GpgFrontend::GpgKey::GetEmail
std::string GetEmail() const
Definition: GpgKey.cpp:60
GpgFrontend::GpgKey::GetSubKeys
std::unique_ptr< std::vector< GpgSubKey > > GetSubKeys() const
Definition: GpgKey.cpp:151
GpgFrontend::UI::KeyPairSubkeyTab::create_subkey_list
void create_subkey_list()
Create a subkey list object.
Definition: KeyPairSubkeyTab.cpp:141
GpgFrontend::UI::KeyPairSubkeyTab::key_size_var_label_
QLabel * key_size_var_label_
Label containing the keys key size.
Definition: KeyPairSubkeyTab.h:80
GpgFrontend::GpgKeyGetter::GetKey
GpgKey GetKey(const std::string &id, bool use_cache=true)
Get the Key object.
Definition: GpgKeyGetter.cpp:47
GpgFrontend::GpgSubKey::GetFingerprint
std::string GetFingerprint() const
Definition: GpgSubKey.cpp:51
GpgFrontend::GpgKey::IsPrivateKey
bool IsPrivateKey() const
Definition: GpgKey.cpp:138
GpgFrontend::UI::KeyPairSubkeyTab::KeyPairSubkeyTab
KeyPairSubkeyTab(const std::string &key, QWidget *parent)
Construct a new Key Pair Subkey Tab object.
Definition: KeyPairSubkeyTab.cpp:36
GpgFrontend::UI::KeyPairSubkeyTab
Definition: KeyPairSubkeyTab.h:39
GpgFrontend::GpgSubKey
Definition: GpgSubKey.h:43
GpgFrontend::UI::SignalStation::GetInstance
static SignalStation * GetInstance()
Get the Instance object.
Definition: SignalStation.cpp:37
GpgFrontend::UI::KeyPairSubkeyTab::algorithm_var_label_
QLabel * algorithm_var_label_
Label containing the keys algorithm.
Definition: KeyPairSubkeyTab.h:83
GpgFrontend::UI::KeyPairSubkeyTab::fingerprint_var_label_
QLabel * fingerprint_var_label_
Label containing the keys fingerprint.
Definition: KeyPairSubkeyTab.h:85
GpgFrontend::UI::KeyPairSubkeyTab::get_selected_subkey
const GpgSubKey & get_selected_subkey()
Get the selected subkey object.
Definition: KeyPairSubkeyTab.cpp:324
GpgFrontend::GpgKey::IsHasMasterKey
bool IsHasMasterKey() const
Definition: GpgKey.cpp:146
GpgFrontend::GpgKey
Definition: GpgKey.h:41