fix paper size is not changed with resolution changed bug
This commit is contained in:
parent
d6246133d8
commit
11a3b02543
|
@ -57,6 +57,7 @@ void image_capture::set_dpi_val(int dpi)
|
||||||
int x = dpi,
|
int x = dpi,
|
||||||
y = dpi;
|
y = dpi;
|
||||||
|
|
||||||
|
dpi_x_ = dpi_y_ = dpi;
|
||||||
if(first)
|
if(first)
|
||||||
first = false;
|
first = false;
|
||||||
else
|
else
|
||||||
|
@ -455,6 +456,8 @@ bool image_capture::update_enabled(const char* name, std::function<GET_SANE_OPT_
|
||||||
|
|
||||||
if(strcmp(name, "paper") == 0)
|
if(strcmp(name, "paper") == 0)
|
||||||
refresh_paper_size(CHG_PAPER_SIZE_FROM_PAPER);
|
refresh_paper_size(CHG_PAPER_SIZE_FROM_PAPER);
|
||||||
|
else if(strcmp(name, "resolution") == 0)
|
||||||
|
refresh_paper_size(CHG_PAPER_SIZE_FROM_DPI);
|
||||||
|
|
||||||
return changed;
|
return changed;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue