aboutsummaryrefslogtreecommitdiffstats
path: root/screen.c
diff options
context:
space:
mode:
authoroga2009-12-10 23:14:58 +0000
committeroga2009-12-10 23:14:58 +0000
commit067d8c9f41a0c6d9cd87c31432b56057e0da2c5d (patch)
tree1a34696a62fbf4f3c12b8a4bdcdc953f71fdb8b1 /screen.c
parent14ac3391c5d071a67de062f4857280212e12afdb (diff)
downloadcwm-067d8c9f41a0c6d9cd87c31432b56057e0da2c5d.tar.gz
Implement _NET_CURRENT_DESKTOP, _NET_DESKTOP_VIEWPORT and
_NET_DESKTOP_GEOMETRY. ok okan@
Diffstat (limited to 'screen.c')
-rw-r--r--screen.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/screen.c b/screen.c
index f53a31b..4e078e7 100644
--- a/screen.c
+++ b/screen.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $Id: screen.c,v 1.20 2009/12/10 17:16:51 oga Exp $
+ * $Id: screen.c,v 1.21 2009/12/10 23:14:58 oga Exp $
*/
#include "headers.h"
@@ -98,3 +98,14 @@ screen_find_xinerama(struct screen_ctx *sc, int x, int y)
}
return (NULL);
}
+
+void
+screen_update_geometry(struct screen_ctx *sc, int width, int height)
+{
+ int geom[2];
+
+ sc->xmax = geom[0] = width;
+ sc->ymax = geom[1] = height;
+ XChangeProperty(X_Dpy, sc->rootwin, _NET_DESKTOP_GEOMETRY,
+ XA_CARDINAL, 32, PropModeReplace, (unsigned char *)geom , 2);
+}