diff options
| author | Dana Jansens <danakj@orodu.net> | 2011-10-14 19:12:11 -0400 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2011-10-16 18:51:51 -0400 |
| commit | c590a83207ed5825b513e2278789ed13f55574b2 (patch) | |
| tree | 86d4c950fdd7cd534c9f5fd94f9abfb887a577c5 /openbox/place.c | |
| parent | a0d14c7d4468b6348d906a68bb5dfe3acce0ad64 (diff) | |
Add "active" and "primary" options to the <monitor> placement option for per-app settings (bug #5180)
Diffstat (limited to 'openbox/place.c')
| -rw-r--r-- | openbox/place.c | 10 |
1 files changed, 9 insertions, 1 deletions
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); } |
