aboutsummaryrefslogtreecommitdiffstats
path: root/src/ui/MainWindow.cpp
diff options
context:
space:
mode:
authorSaturneric <[email protected]>2021-12-05 18:51:59 +0000
committerSaturneric <[email protected]>2021-12-05 19:00:26 +0000
commit590f222de4abdf2aae4d2d8de6f9af25996a713e (patch)
tree4108a6205fb517a694d65b3044f7369f32b43862 /src/ui/MainWindow.cpp
parentAdd Submodules & Update & Fixed (diff)
downloadGpgFrontend-590f222de4abdf2aae4d2d8de6f9af25996a713e.tar.gz
GpgFrontend-590f222de4abdf2aae4d2d8de6f9af25996a713e.zip
Improve UI
1. Support Key List Tab 2. File Hash Calculate 3. File Rename 4. Fix known bugs 5. Fix known ci issues.
Diffstat (limited to 'src/ui/MainWindow.cpp')
-rw-r--r--src/ui/MainWindow.cpp14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/ui/MainWindow.cpp b/src/ui/MainWindow.cpp
index e29278e9..d13a0bd5 100644
--- a/src/ui/MainWindow.cpp
+++ b/src/ui/MainWindow.cpp
@@ -59,14 +59,7 @@ void MainWindow::init() noexcept {
setCentralWidget(edit);
/* the list of Keys available*/
- mKeyList = new KeyList(KeyListRow::SECRET_OR_PUBLIC_KEY,
- KeyListColumn::TYPE | KeyListColumn::NAME |
- KeyListColumn::EmailAddress |
- KeyListColumn::Usage | KeyListColumn::Validity,
- this);
- mKeyList->setFilter([](const GpgKey& key) -> bool {
- return !(key.revoked() || key.disabled() || key.expired());
- });
+ mKeyList = new KeyList(this);
mKeyList->slotRefresh();
@@ -144,7 +137,6 @@ void MainWindow::init() noexcept {
&MainWindow::slotVersionUpgrade);
version_thread->start();
-
#endif
} catch (...) {
@@ -244,7 +236,6 @@ void MainWindow::restoreSettings() {
// icons ize
this->setIconSize(QSize(width, height));
importButton->setIconSize(QSize(width, height));
- fileEncButton->setIconSize(QSize(width, height));
if (!settings.exists("keyserver") ||
settings.lookup("keyserver").getType() != libconfig::Setting::TypeGroup)
@@ -279,7 +270,6 @@ void MainWindow::restoreSettings() {
auto icon_style = static_cast<Qt::ToolButtonStyle>(s_icon_style);
this->setToolButtonStyle(icon_style);
importButton->setToolButtonStyle(icon_style);
- fileEncButton->setToolButtonStyle(icon_style);
if (!settings.exists("general") ||
settings.lookup("general").getType() != libconfig::Setting::TypeGroup)
@@ -300,12 +290,12 @@ void MainWindow::restoreSettings() {
general.add("save_key_checked_key_ids", libconfig::Setting::TypeList);
}
auto key_ids_ptr = std::make_unique<KeyIdArgsList>();
- ;
auto& save_key_checked_key_ids = general["save_key_checked_key_ids"];
const auto key_ids_size =
general.lookup("save_key_checked_key_ids").getLength();
for (auto i = 0; i < key_ids_size; i++) {
std::string key_id = save_key_checked_key_ids[i];
+ LOG(INFO) << "get checked key id" << key_id;
key_ids_ptr->push_back(key_id);
}
mKeyList->setChecked(key_ids_ptr);