aboutsummaryrefslogtreecommitdiffstats
path: root/src/ui/dialog/GeneralDialog.cpp
diff options
context:
space:
mode:
authorSaturneric <[email protected]>2022-07-22 18:54:52 +0000
committerSaturneric <[email protected]>2022-07-22 18:56:08 +0000
commitff73042072c1937c8ee20cabab3f16cf38d588b1 (patch)
treef269b6178a5318cbf1c7945bbcd6d7a0736d104f /src/ui/dialog/GeneralDialog.cpp
parentrefactor(ui): adjust file structure (diff)
downloadGpgFrontend-ff73042072c1937c8ee20cabab3f16cf38d588b1.tar.gz
GpgFrontend-ff73042072c1937c8ee20cabab3f16cf38d588b1.zip
fix(ui): fix signer picker and other issues
1. signer picker can cancel its operation now 2. fix window title of "Export As Key Package"
Diffstat (limited to 'src/ui/dialog/GeneralDialog.cpp')
-rw-r--r--src/ui/dialog/GeneralDialog.cpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/ui/dialog/GeneralDialog.cpp b/src/ui/dialog/GeneralDialog.cpp
index 457aa142..d07c2497 100644
--- a/src/ui/dialog/GeneralDialog.cpp
+++ b/src/ui/dialog/GeneralDialog.cpp
@@ -50,16 +50,17 @@ void GpgFrontend::UI::GeneralDialog::slot_restore_settings() noexcept {
int x = general_windows_state.Check("window_pos").Check("x", 100),
y = general_windows_state.Check("window_pos").Check("y", 100);
- auto pos = QPoint(x, y);
+ this->move({x, y});
+ pos_ = {x, y};
int width =
- general_windows_state.Check("window_size").Check("width", 800),
+ general_windows_state.Check("window_size").Check("width", 400),
height =
- general_windows_state.Check("window_size").Check("height", 450);
+ general_windows_state.Check("window_size").Check("height", 247);
+
+ this->resize({width, height});
+ size_ = {width, height};
- auto size = QSize(width, height);
- this->resize(size);
- this->move(pos);
}
} catch (...) {
@@ -77,8 +78,8 @@ void GpgFrontend::UI::GeneralDialog::slot_save_settings() noexcept {
general_windows_state["window_pos"]["x"] = pos().x();
general_windows_state["window_pos"]["y"] = pos().y();
- general_windows_state["window_size"]["width"] = size().width();
- general_windows_state["window_size"]["height"] = size().height();
+ general_windows_state["window_size"]["width"] = size_.width();
+ general_windows_state["window_size"]["height"] = size_.height();
general_windows_state["window_save"] = true;
} catch (...) {