From c590a83207ed5825b513e2278789ed13f55574b2 Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Fri, 14 Oct 2011 19:12:11 -0400 Subject: Add "active" and "primary" options to the placement option for per-app settings (bug #5180) --- openbox/place.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'openbox/place.c') diff --git a/openbox/place.c b/openbox/place.c index a13bc2cb..8a4a4264 100644 --- a/openbox/place.c +++ b/openbox/place.c @@ -451,7 +451,15 @@ static gboolean place_per_app_setting(ObClient *client, gint *x, gint *y, ob_debug("placing by per-app settings"); /* Find which head the pointer is on */ - if (settings->monitor == 0) { + if (settings->monitor_type == OB_APP_SETTINGS_MONITOR_PRIMARY) { + guint m = screen_monitor_primary(TRUE); + screen = screen_area(client->desktop, m, NULL); + } + else if (settings->monitor_type == OB_APP_SETTINGS_MONITOR_ACTIVE) { + guint m = screen_monitor_active(); + screen = screen_area(client->desktop, m, NULL); + } + else if (settings->monitor_type == OB_APP_SETTINGS_MONITOR_MOUSE) { screen = pick_pointer_head(client); g_assert(screen); } -- cgit v1.2.3