diff options
author | saturneric <[email protected]> | 2025-04-13 19:33:31 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2025-04-13 19:33:31 +0000 |
commit | 7ca18eb0e2c4204f749c682b66c862968e8d2f58 (patch) | |
tree | ba8e0303ebc6ec376b1be580408d9cd91f58f2d8 /src/ui/dialog/controller/SmartCardControllerDialog.h | |
parent | feat: add openpgp smart card support (diff) | |
download | GpgFrontend-7ca18eb0e2c4204f749c682b66c862968e8d2f58.tar.gz GpgFrontend-7ca18eb0e2c4204f749c682b66c862968e8d2f58.zip |
feat: add SmartCardController
Diffstat (limited to 'src/ui/dialog/controller/SmartCardControllerDialog.h')
-rw-r--r-- | src/ui/dialog/controller/SmartCardControllerDialog.h | 50 |
1 files changed, 46 insertions, 4 deletions
diff --git a/src/ui/dialog/controller/SmartCardControllerDialog.h b/src/ui/dialog/controller/SmartCardControllerDialog.h index 9b71bba7..83a717ee 100644 --- a/src/ui/dialog/controller/SmartCardControllerDialog.h +++ b/src/ui/dialog/controller/SmartCardControllerDialog.h @@ -29,6 +29,7 @@ #pragma once #include "core/model/GpgOpenPGPCard.h" +#include "core/typedef/CoreTypedef.h" #include "ui/dialog/GeneralDialog.h" class Ui_SmartCardControllerDialog; @@ -52,23 +53,44 @@ class SmartCardControllerDialog : public GeneralDialog { */ void slot_refresh(); + /** + * @brief + * + */ + void slot_listen_smart_card_changes(); + + /** + * @brief + * + * @param disable + */ + void slot_disable_controllers(bool disable); + + /** + * @brief + * + */ + void slot_fetch_smart_card_keys(); + private: QSharedPointer<Ui_SmartCardControllerDialog> ui_; ///< int channel_; - QString serial_number_; + bool has_card_; GpgOpenPGPCard card_info_; + QString cached_status_hash_; + QTimer* timer_; /** * @brief Get the smart card serial number object * */ - void get_smart_card_serial_number(); + void select_smart_card_by_serial_number(const QString& serial_number); /** * @brief * */ - void fetch_smart_card_info(); + void fetch_smart_card_info(const QString& serial_number); /** * @brief @@ -80,6 +102,26 @@ class SmartCardControllerDialog : public GeneralDialog { * @brief * */ - void refresh_key_tree_view(); + void refresh_key_tree_view(int channel); + + /** + * @brief + * + */ + void reset_status(); + + /** + * @brief + * + * @param attr + */ + void modify_key_attribute(const QString& attr); + + /** + * @brief + * + * @param attr + */ + void modify_key_pin(const QString& pinref); }; } // namespace GpgFrontend::UI |