add a sanity check for the snap offset, limiting it to 50
This commit is contained in:
parent
dba5b809ec
commit
08e28f38a9
1 changed files with 2 additions and 0 deletions
|
@ -684,6 +684,8 @@ void BScreen::load_rc(void) {
|
||||||
if (! config->getValue(screenstr + "edgeSnapOffset",
|
if (! config->getValue(screenstr + "edgeSnapOffset",
|
||||||
resource.snap_offset))
|
resource.snap_offset))
|
||||||
resource.snap_offset = 0;
|
resource.snap_offset = 0;
|
||||||
|
if (resource.snap_offset > 50) // sanity check, setting this huge would
|
||||||
|
resource.snap_offset = 50; // seriously suck.
|
||||||
|
|
||||||
if (! config->getValue(screenstr + "edgeSnapThreshold",
|
if (! config->getValue(screenstr + "edgeSnapThreshold",
|
||||||
resource.snap_threshold))
|
resource.snap_threshold))
|
||||||
|
|
Loading…
Reference in a new issue