From 339ab523850f7e8ae11a43ac4e79ce60b4978789 Mon Sep 17 00:00:00 2001 From: gb <741021719@qq.com> Date: Tue, 10 May 2022 10:33:02 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=88=87=E6=8D=A2=E6=89=AB?= =?UTF-8?q?=E6=8F=8F=E7=BA=B8=E5=BC=A0=E6=97=B6=EF=BC=8C=E8=87=AA=E5=AE=9A?= =?UTF-8?q?=E4=B9=89=E6=89=AB=E6=8F=8F=E5=8C=BA=E5=9F=9F=E6=8E=A7=E4=BB=B6?= =?UTF-8?q?=E7=BB=84=E6=98=BE=E7=A4=BA/=E9=9A=90=E8=97=8FBUG?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/scanner/hg_settingdialog.cpp | 15 +++++++++++++++ app/scanner/hg_settingdialog.h | 1 + 2 files changed, 16 insertions(+) diff --git a/app/scanner/hg_settingdialog.cpp b/app/scanner/hg_settingdialog.cpp index f32b6e6a..7e2d79f1 100644 --- a/app/scanner/hg_settingdialog.cpp +++ b/app/scanner/hg_settingdialog.cpp @@ -15,6 +15,7 @@ hg_settingdialog::hg_settingdialog(void *handle, QWidget *parent : QDialog(parent) , schemes_(cfg), cur_ind_(cfg->cur_scheme), changed_count_(0), save_(false) , btn_cut_area_(nullptr), btn_gamma_(nullptr), cfg_file_(nullptr), clicked_gamma_(false) + , custom_area_lable_(nullptr) { m_dpiId = -1; m_dpiValue = 200; @@ -340,6 +341,7 @@ void hg_settingdialog::createUI() btn_cut_area_->setFixedWidth(120); h->addWidget(btn_cut_area_); + custom_area_lable_ = title; reinterpret_cast(widget->layout())->addRow(h); connect(btn_cut_area_, SIGNAL(clicked(bool)), this, SLOT(slot_cutButtonClicked())); } @@ -898,6 +900,19 @@ void hg_settingdialog::updateUIStatus() if(w_label) hide ? w_label->hide() : w_label->show(); widget->setVisible(!hide); + if(strcmp(opt->title, OPTION_TITLE_ZDYSMQY) == 0) + { + if(hide) + { + custom_area_lable_->hide(); + btn_cut_area_->hide(); + } + else + { + custom_area_lable_->show(); + btn_cut_area_->show(); + } + } } // Temporarily block the multi-stream output function diff --git a/app/scanner/hg_settingdialog.h b/app/scanner/hg_settingdialog.h index 1dfeccff..5a30a0ed 100644 --- a/app/scanner/hg_settingdialog.h +++ b/app/scanner/hg_settingdialog.h @@ -43,6 +43,7 @@ class hg_settingdialog : public QDialog QPushButton *apply_; QPushButton *del_this_; QPushButton *del_all_; + QLabel *custom_area_lable_; QPushButton *btn_cut_area_; QPushButton *btn_gamma_; QTextEdit *sketch_;