summaryrefslogtreecommitdiff
path: root/openbox/config.c
diff options
context:
space:
mode:
authorDana Jansens <danakj@orodu.net>2009-12-09 10:32:36 -0500
committerDana Jansens <danakj@orodu.net>2009-12-09 10:32:36 -0500
commit301122057283400dda30cd8ed04c7b7b69e4a912 (patch)
tree4f84dff4d62eb9a7932d265b3d27c6c4a2def801 /openbox/config.c
parent5290af9f50c8492398e9f1c61be8f659106bc591 (diff)
Set a minimum value for the screenEdgeWarpTime for 25ms.
When this is very small it just gives X/Openbox a heart attack and ends up going forever. Even 25 is quite too fast to be usuable so it should be a good minimum.
Diffstat (limited to 'openbox/config.c')
-rw-r--r--openbox/config.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/openbox/config.c b/openbox/config.c
index 96fdd0f4..9b6c2028 100644
--- a/openbox/config.c
+++ b/openbox/config.c
@@ -444,8 +444,13 @@ static void parse_mouse(ObParseInst *i, xmlDocPtr doc, xmlNodePtr node,
config_mouse_threshold = parse_int(doc, n);
if ((n = parse_find_node("doubleClickTime", node)))
config_mouse_dclicktime = parse_int(doc, n);
- if ((n = parse_find_node("screenEdgeWarpTime", node)))
+ if ((n = parse_find_node("screenEdgeWarpTime", node))) {
config_mouse_screenedgetime = parse_int(doc, n);
+ /* minimum value of 25 for this property, when it is 1 and you hit the
+ edge it basically never stops */
+ if (config_mouse_screenedgetime && config_mouse_screenedgetime < 25)
+ config_mouse_screenedgetime = 25;
+ }
n = parse_find_node("context", node);
while (n) {