GpgFrontend Project
A Free, Powerful, Easy-to-Use, Compact, Cross-Platform, and Installation-Free OpenPGP(pgp) Crypto Tool.
GpgFrontend::UI::SubkeyGenerateDialog Class Reference
Inheritance diagram for GpgFrontend::UI::SubkeyGenerateDialog:
Inheritance graph
Collaboration diagram for GpgFrontend::UI::SubkeyGenerateDialog:
Collaboration graph

Public Member Functions

 SubkeyGenerateDialog (const KeyId &key_id, QWidget *parent)
 Construct a new Subkey Generate Dialog object. More...
 
- Public Member Functions inherited from GpgFrontend::UI::GeneralDialog
 GeneralDialog (QString name, QWidget *parent=nullptr)
 

Private Slots

void slot_expire_box_changed ()
 
void slot_key_gen_accept ()
 
void slot_encryption_box_changed (int state)
 
void slot_signing_box_changed (int state)
 
void slot_certification_box_changed (int state)
 
void slot_authentication_box_changed (int state)
 
void slot_activated_key_type (int index)
 

Private Member Functions

QGroupBox * create_key_usage_group_box ()
 Create a key usage group box object. More...
 
QGroupBox * create_basic_info_group_box ()
 Create a basic info group box object. More...
 
void set_signal_slot ()
 Set the signal slot object.
 
void refresh_widgets_state ()
 

Private Attributes

GpgKey key_
 
std::shared_ptr< GenKeyInfogen_key_info_
 
QGroupBox * key_usage_group_box_ {}
 
QDialogButtonBox * button_box_
 Box for standard buttons.
 
QLabel * error_label_ {}
 Label containing error message.
 
QSpinBox * key_size_spin_box_ {}
 Spinbox for the keys size (in bit)
 
QComboBox * key_type_combo_box_ {}
 Combobox for Key tpe.
 
QDateTimeEdit * date_edit_ {}
 Date edit for expiration date.
 
QCheckBox * expire_check_box_ {}
 Checkbox, if key should expire.
 
QCheckBox * no_pass_phrase_check_box_ {}
 Checkbox, if key should expire.
 
std::vector< QCheckBox * > key_usage_check_boxes_
 ENCR, SIGN, CERT, AUTH.
 
QDateTime max_date_time_
 

Additional Inherited Members

- Protected Member Functions inherited from GpgFrontend::UI::GeneralDialog
void setPosCenterOfScreen ()
 
void movePosition2CenterOfParent ()
 
bool isRectRestored ()
 
void showEvent (QShowEvent *event) override
 

Constructor & Destructor Documentation

◆ SubkeyGenerateDialog()

GpgFrontend::UI::SubkeyGenerateDialog::SubkeyGenerateDialog ( const KeyId &  key_id,
QWidget *  parent 
)
explicit

Member Function Documentation

◆ create_basic_info_group_box()

QGroupBox * GpgFrontend::UI::SubkeyGenerateDialog::create_basic_info_group_box ( )
private

◆ create_key_usage_group_box()

QGroupBox * GpgFrontend::UI::SubkeyGenerateDialog::create_key_usage_group_box ( )
private

Create a key usage group box object.

Returns
QGroupBox*

References key_usage_check_boxes_.

Referenced by SubkeyGenerateDialog().

◆ refresh_widgets_state()

void GpgFrontend::UI::SubkeyGenerateDialog::refresh_widgets_state ( )
private

Refresh widgets state by GenKeyInfo

References key_size_spin_box_, and key_usage_check_boxes_.

Referenced by slot_activated_key_type(), and SubkeyGenerateDialog().

◆ slot_activated_key_type

void GpgFrontend::UI::SubkeyGenerateDialog::slot_activated_key_type ( int  index)
privateslot
Parameters
index

References refresh_widgets_state().

Referenced by set_signal_slot().

◆ slot_authentication_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_authentication_box_changed ( int  state)
privateslot
Parameters
state

Referenced by set_signal_slot().

◆ slot_certification_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_certification_box_changed ( int  state)
privateslot
Parameters
state

Referenced by set_signal_slot().

◆ slot_encryption_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_encryption_box_changed ( int  state)
privateslot
Parameters
state

Referenced by set_signal_slot().

◆ slot_expire_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_expire_box_changed ( )
privateslot

when expire box was checked/unchecked, enable/disable the expiration date box

References date_edit_, and expire_check_box_.

Referenced by set_signal_slot().

◆ slot_key_gen_accept

void GpgFrontend::UI::SubkeyGenerateDialog::slot_key_gen_accept ( )
privateslot

check all line edits for false entries. Show error, when there is one, otherwise generate the key

primary keys should have a reasonable expiration date (no more than 2 years in the future)

create error message

References GpgFrontend::CheckGpgError(), date_edit_, error_label_, expire_check_box_, GpgFrontend::UI::UISignalStation::GetInstance(), GpgFrontend::SingletonFunctionObject< GpgKeyOpera >::GetInstance(), key_size_spin_box_, GpgFrontend::UI::CommonUtils::RaiseMessageBox(), and GpgFrontend::UI::CommonUtils::WaitForOpera().

Referenced by set_signal_slot().

◆ slot_signing_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_signing_box_changed ( int  state)
privateslot
Parameters
state

Referenced by set_signal_slot().

Member Data Documentation

◆ gen_key_info_

std::shared_ptr<GenKeyInfo> GpgFrontend::UI::SubkeyGenerateDialog::gen_key_info_
private
Initial value:
=
SecureCreateSharedObject<GenKeyInfo>(true)

The documentation for this class was generated from the following files: