From 111465b7373cdcdd791b603aefd882ae06d5bf0b Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Mon, 14 Dec 2009 16:08:30 -0500 Subject: Let menus place themselves on monitors where the mouse is not present This fixes a bug which forced menus to show up on the same monitor as the mouse pointer. --- openbox/screen.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'openbox/screen.h') diff --git a/openbox/screen.h b/openbox/screen.h index 7df47f39..4a8d8a1e 100644 --- a/openbox/screen.h +++ b/openbox/screen.h @@ -134,6 +134,9 @@ gboolean screen_physical_area_monitor_contains(guint head, Rect *search); */ guint screen_find_monitor(Rect *search); +/*! Finds the monitor which contains the point @x, @y */ +guint screen_find_monitor_point(guint x, guint y); + /*! Sets the root cursor. This function decides which cursor to use, but you gotta call it to let it know it should change. */ void screen_set_root_cursor(); -- cgit v1.2.3 From 3c688bc4a75436a457d3ce693eda6bd6b329412f Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Tue, 15 Dec 2009 14:53:29 -0500 Subject: Make the NET_WORKAREA hint work the way it used to, across all monitors The spec is not going to change this hint, but rather add a new one. So for now just revert to the old behaviour. --- openbox/screen.h | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'openbox/screen.h') diff --git a/openbox/screen.h b/openbox/screen.h index 4a8d8a1e..16903300 100644 --- a/openbox/screen.h +++ b/openbox/screen.h @@ -110,10 +110,18 @@ guint screen_monitor_active(void); Rect *screen_physical_area_active(void); -/*! Returns the primary monitor, as specified by the config */ -guint screen_monitor_primary(void); +/*! Returns the primary monitor, as specified by the config. + @fixed If TRUE, then this will always return a fixed monitor, otherwise + it may change based on where focus is, or other heuristics. + */ +guint screen_monitor_primary(gboolean fixed); -Rect *screen_physical_area_primary(void); +/*! Returns physical area for the primary monitor, as specified by the config. + @fixed If TRUE, then this will always use a fixed monitor as primary, + otherwise it may change based on where focus is, or other heuristics. + See screen_monitor_primary(). +*/ +Rect *screen_physical_area_primary(gboolean fixed); /* doesn't include struts which the search area is already outside of when 'search' is not NULL */ -- cgit v1.2.3