cur->desktop != screen_desktop)
continue;
- ob_debug("trying window %s\n", cur->title);
+ ob_debug("trying window %s", cur->title);
- detect_edge(cur->frame->area, dir, my_head, my_size, my_edge_start,
+ RECT_SET(expand, cur->frame->area.x - config_window_margin,
+ cur->frame->area.y - config_window_margin,
+ cur->frame->area.width + config_window_margin * 2,
+ cur->frame->area.height + config_window_margin * 2);
+ detect_edge(expand, dir, my_head, my_size, my_edge_start,
my_edge_size, dest, near_edge);
}
dock_get_area(&dock_area);
xmlNodePtr n;
node = node->children;
- if ((n = parse_find_node("strength", node)))
- config_resist_win = parse_int(doc, n);
- if ((n = parse_find_node("screen_edge_strength", node)))
- config_resist_edge = parse_int(doc, n);
+ if ((n = obt_parse_find_node(node, "strength")))
+ config_resist_win = obt_parse_node_int(n);
+ if ((n = obt_parse_find_node(node, "screen_edge_strength")))
+ config_resist_edge = obt_parse_node_int(n);
}
-static void parse_window_margin(ObParseInst *i, xmlDocPtr doc, xmlNodePtr node,
- gpointer data)
++static void parse_window_margin(xmlNodePtr node, gpointer d)
+ {
- config_window_margin = parse_int(doc, node);
++ config_window_margin = obt_parse_node_int(node);
+ }
+
typedef struct
{
const gchar *key;
config_resist_win = 10;
config_resist_edge = 20;
- parse_register(i, "resistance", parse_resistance, NULL);
+ obt_parse_register(i, "resistance", parse_resistance, NULL);
- parse_register(i, "windowMargin", parse_window_margin, NULL);
+ config_window_margin = 0;
+
++ obt_parse_register(i, "windowMargin", parse_window_margin, NULL);
+
config_menu_hide_delay = 250;
config_menu_middle = FALSE;
config_submenu_show_delay = 0;
/* don't snap to self or non-visibles */
if (!target->frame->visible || target == c)
continue;
- /* don't snap to windows set to below and skip_taskbar (desklets) */
- if (target->below && !c->below && target->skip_taskbar)
- continue;
+ /* check window boundary as it is */
if (resist_move_window(c->frame->area, target->frame->area,
resist, x, y))
break;
/* don't snap to invisibles or ourself */
if (!target->frame->visible || target == c)
continue;
- /* don't snap to windows set to below and skip_taskbar (desklets) */
- if (target->below && !c->below && target->skip_taskbar)
- continue;
+ /* check window boundary as it is */
if (resist_size_window(c->frame->area, target->frame->area,
resist, w, h, dir))
break;