From ed9788e18a58f8800a6c7fe82fcadf77b2b38238 Mon Sep 17 00:00:00 2001 From: yangjiaxuan <171295266@qq.com> Date: Thu, 13 Oct 2022 15:14:20 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=83=A8=E5=88=86title?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E4=B8=BAname=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/scanner/mainwindow.cpp | 2 +- app/scanner/sane_device.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/scanner/mainwindow.cpp b/app/scanner/mainwindow.cpp index 0c73fbc9..12ce3f86 100644 --- a/app/scanner/mainwindow.cpp +++ b/app/scanner/mainwindow.cpp @@ -1317,7 +1317,7 @@ HGUInt MainWindow::getDpi() { SANE_Int value = 0; sane_control_option(cur_dev_.handle(), i, SANE_ACTION_GET_VALUE, &value, nullptr); - if (0 == strcmp(desp->title, OPTION_TITLE_FBL)) + if (0 == strcmp(desp->name, SANE_STD_OPT_NAME_RESOLUTION)) { dpi = (HGUInt)value; } diff --git a/app/scanner/sane_device.cpp b/app/scanner/sane_device.cpp index 041de336..d16a7d2c 100644 --- a/app/scanner/sane_device.cpp +++ b/app/scanner/sane_device.cpp @@ -99,7 +99,7 @@ sane_dev::act_result sane_dev::apply(const SANE_Option_Descriptor* desc, int opt if(str) delete[] str; - if(cfg->name == OPTION_TITLE_QYSDQX && cfg->val == "true") + if(cfg->name == SANE_STD_OPT_NAME_IS_CUSTOM_GAMMA && cfg->val == "true") { SANE_Gamma gamma = {0}; unsigned int l = 0;