From face7439282c844897568e7a17d3094102580d38 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Fri, 17 Dec 2021 19:00:41 +0100 Subject: video/ps3eye: set dialog attributes in the right place --- video-ps3eye/module.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'video-ps3eye/module.cpp') diff --git a/video-ps3eye/module.cpp b/video-ps3eye/module.cpp index 28283e6b..02543082 100644 --- a/video-ps3eye/module.cpp +++ b/video-ps3eye/module.cpp @@ -92,7 +92,11 @@ std::unique_ptr ps3eye_camera_::make_camera(const QString& name) static bool show_dialog_() { - (new dialog)->show(); + auto& dlg = *new dialog; + dlg.setWindowFlag(Qt::MSWindowsFixedSizeDialogHint); + dlg.setAttribute(Qt::WA_DeleteOnClose); + dlg.adjustSize(); dlg.setFixedSize(dlg.size()); + dlg.show(); return true; } @@ -257,9 +261,6 @@ OTR_REGISTER_CAMERA(ps3eye_camera_) dialog::dialog(QWidget* parent) : QWidget(parent) { ui.setupUi(this); - adjustSize(); setFixedSize(size()); - setAttribute(Qt::WA_DeleteOnClose); - t.setInterval(500); t.setSingleShot(true); tie_setting(s.exposure, ui.exposure_slider); tie_setting(s.gain, ui.gain_slider); -- cgit v1.2.3