aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSaturneric <[email protected]>2021-06-24 09:51:58 +0000
committerSaturneric <[email protected]>2021-06-24 09:51:58 +0000
commite0f72fd046da0ad32f04cba98164a82b7819c9ac (patch)
tree937c9ba0a15a0d7df6fa98b76093cb897ec6ed91
parentMerge branch 'develop' into main (diff)
downloadGpgFrontend-e0f72fd046da0ad32f04cba98164a82b7819c9ac.tar.gz
GpgFrontend-e0f72fd046da0ad32f04cba98164a82b7819c9ac.zip
Update Document.
Fix Bugs in UI.
-rw-r--r--CMakeLists.txt2
-rw-r--r--README.md8
-rw-r--r--src/ui/keypair_details/KeyPairSubkeyTab.cpp2
-rw-r--r--src/ui/keypair_details/KeyPairUIDTab.cpp20
4 files changed, 21 insertions, 11 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5cb9ebf8..a3a3ea4c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,6 +1,6 @@
cmake_minimum_required(VERSION 3.16)
-project(GpgFrontend VERSION 1.0.4 LANGUAGES CXX)
+project(GpgFrontend VERSION 1.0.5 LANGUAGES CXX)
message(STATUS "GPGFrontend Build Configuration Started CMAKE Version ${CMAKE_VERSION}")
diff --git a/README.md b/README.md
index 1568b558..4b33a956 100644
--- a/README.md
+++ b/README.md
@@ -14,10 +14,12 @@ Frontend Tool.
By using GpgFrontend, you can quickly **encrypt and decrypt text or files**. Or at the same time as the above
operations, you can add **your own signature** to let others know that this document or this paragraph of text was
-issued by you.
+issued by you. It aims to allow ordinary users to quickly use gpg and make professional users more convenient.
+GpgFrontend supports new features of OpenPGP.
-Furthermore, it visualizes most of the common operations of gpg commands. It aims to allow ordinary users to quickly use
-gpg and make professional users more convenient. GpgFrontend supports new features of OpenPGP.
+**Notice:** GpgFrontend does not provide an embedded [gnupg](https://gnupg.org/) binary library and needs to be
+installed by the user. **This is to ensure safety and avoid code or binary files being implanted in the backdoor during
+the delivery process.**
[ >> Quick Start](#quick-start)
diff --git a/src/ui/keypair_details/KeyPairSubkeyTab.cpp b/src/ui/keypair_details/KeyPairSubkeyTab.cpp
index 84042323..c5647553 100644
--- a/src/ui/keypair_details/KeyPairSubkeyTab.cpp
+++ b/src/ui/keypair_details/KeyPairSubkeyTab.cpp
@@ -35,7 +35,7 @@ KeyPairSubkeyTab::KeyPairSubkeyTab(GpgME::GpgContext *ctx, const GpgKey &key, QW
auto uidButtonsLayout = new QGridLayout();
auto addSubkeyButton = new QPushButton(tr("Generate A New Subkey"));
- if(!mKey.is_private_key) {
+ if(!mKey.is_private_key || !mKey.has_master_key) {
addSubkeyButton->setDisabled(true);
setHidden(addSubkeyButton);
}
diff --git a/src/ui/keypair_details/KeyPairUIDTab.cpp b/src/ui/keypair_details/KeyPairUIDTab.cpp
index 1a6c769d..51f188bd 100644
--- a/src/ui/keypair_details/KeyPairUIDTab.cpp
+++ b/src/ui/keypair_details/KeyPairUIDTab.cpp
@@ -39,7 +39,11 @@ KeyPairUIDTab::KeyPairUIDTab(GpgME::GpgContext *ctx, const GpgKey &key, QWidget
auto addUIDButton = new QPushButton(tr("New UID"));
auto manageUIDButton = new QPushButton(tr("UID Management"));
- manageUIDButton->setMenu(manageSelectedUIDMenu);
+ if(mKey.has_master_key) {
+ manageUIDButton->setMenu(manageSelectedUIDMenu);
+ } else {
+ manageUIDButton->setDisabled(true);
+ }
uidButtonsLayout->addWidget(addUIDButton, 0, 1);
uidButtonsLayout->addWidget(manageUIDButton, 0, 2);
@@ -258,8 +262,10 @@ void KeyPairUIDTab::createManageUIDMenu() {
auto *delUIDAct = new QAction(tr("Delete Selected UID(s)"), this);
connect(delUIDAct, SIGNAL(triggered()), this, SLOT(slotDelUID()));
- manageSelectedUIDMenu->addAction(signUIDAct);
- manageSelectedUIDMenu->addAction(delUIDAct);
+ if(mKey.has_master_key) {
+ manageSelectedUIDMenu->addAction(signUIDAct);
+ manageSelectedUIDMenu->addAction(delUIDAct);
+ }
}
void KeyPairUIDTab::slotAddUID() {
@@ -390,9 +396,11 @@ void KeyPairUIDTab::createUIDPopupMenu() {
auto *delUIDAct = new QAction(tr("Delete UID"), this);
connect(delUIDAct, SIGNAL(triggered()), this, SLOT(slotDelUIDSingle()));
- uidPopupMenu->addAction(serPrimaryUIDAct);
- uidPopupMenu->addAction(signUIDAct);
- uidPopupMenu->addAction(delUIDAct);
+ if(mKey.has_master_key) {
+ uidPopupMenu->addAction(serPrimaryUIDAct);
+ uidPopupMenu->addAction(signUIDAct);
+ uidPopupMenu->addAction(delUIDAct);
+ }
}
void KeyPairUIDTab::contextMenuEvent(QContextMenuEvent *event) {