Fix incorrect pixelsize use where DPI scale was intended

Changing line-width shouldn't scale cursor motion. Related to T79787.

Use dpi_fac for scaling curve error threshold & number button drag
threshold calculation.
This commit is contained in:
2020-08-18 11:53:53 +10:00
parent 6978635622
commit d1057890c4
2 changed files with 3 additions and 3 deletions

View File

@@ -4790,7 +4790,7 @@ static bool ui_numedit_but_NUM(uiBut *but,
if (is_float == false) {
/* at minimum, moving cursor 2 pixels should change an int button. */
CLAMP_MIN(non_linear_scale, 0.5f * U.pixelsize);
CLAMP_MIN(non_linear_scale, 0.5f * UI_DPI_FAC);
}
data->dragf += (((float)(mx - data->draglastx)) / deler) * non_linear_scale;