修改在设备菜单选择配置,不能记住用户当前选择的BUG
This commit is contained in:
parent
be2a3b9951
commit
82146776f7
|
@ -2769,8 +2769,14 @@ void MainWindow::on_scanOptions_changed(const QString &device, const QString &op
|
|||
|
||||
DEVCFG& cfg = dev_schemes_[ind];
|
||||
std::vector<OPTSCHEME>::iterator it = std::find(cfg.schemes.begin(), cfg.schemes.end(), option.toStdString());
|
||||
if(it != cfg.schemes.end())
|
||||
if(it == cfg.schemes.end())
|
||||
cfg.cur_scheme = -1;
|
||||
else {
|
||||
schm = &(*it);
|
||||
cfg.cur_scheme = it - cfg.schemes.begin() - 1;
|
||||
}
|
||||
m_config.save_scanner_configs(&cfg);
|
||||
|
||||
if(cur_dev_.name() != device.toStdString())
|
||||
{
|
||||
if(!open_scanner(device, schm))
|
||||
|
|
Loading…
Reference in New Issue