diff options
author | saturneric <[email protected]> | 2025-04-29 13:19:06 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2025-04-29 13:19:06 +0000 |
commit | 6106b66c879ecbdf5dec6dd8b63db383efca0844 (patch) | |
tree | 19327805289c783ec2a07449746170d614082e56 /src/ui/main_window/MainWindow.cpp | |
parent | fix: filename of export key is not correct (diff) | |
download | GpgFrontend-6106b66c879ecbdf5dec6dd8b63db383efca0844.tar.gz GpgFrontend-6106b66c879ecbdf5dec6dd8b63db383efca0844.zip |
fix: add to favorite function not works properly
Diffstat (limited to '')
-rw-r--r-- | src/ui/main_window/MainWindow.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/ui/main_window/MainWindow.cpp b/src/ui/main_window/MainWindow.cpp index e2c4f1e3..76830691 100644 --- a/src/ui/main_window/MainWindow.cpp +++ b/src/ui/main_window/MainWindow.cpp @@ -305,12 +305,15 @@ void MainWindow::slot_popup_menu_by_key_list(QContextMenuEvent* event, if (event == nullptr || key_table == nullptr) return; const auto key_table_name = key_table->objectName(); + + LOG_D() << "current key table object name: " << key_table_name; + if (key_table_name == "favourite") { - remove_key_from_favourtie_act_->setDisabled(true); - add_key_2_favourite_act_->setDisabled(false); + remove_key_from_favourtie_act_->setVisible(true); + add_key_2_favourite_act_->setVisible(false); } else { - remove_key_from_favourtie_act_->setDisabled(false); - add_key_2_favourite_act_->setDisabled(true); + remove_key_from_favourtie_act_->setVisible(false); + add_key_2_favourite_act_->setVisible(true); } popup_menu_->popup(event->globalPos()); |