diff options
author | Daniel Friesel <derf@derf.homelinux.org> | 2010-02-05 18:06:58 +0100 |
---|---|---|
committer | Daniel Friesel <derf@derf.homelinux.org> | 2010-02-05 18:06:58 +0100 |
commit | 97443813d3dd7988cb3b0197a62c79ca1b465003 (patch) | |
tree | eca7fd45da9cc0d8a8fa6a2ae82d527f954e1c2a | |
parent | b15926352cbd4b56cfded66af126a4e7378c6178 (diff) |
Apply 02_changeset_r54_x_window_resize.patch from Debian
-rw-r--r-- | src/winwidget.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/winwidget.c b/src/winwidget.c index 8525a17..38d6db6 100644 --- a/src/winwidget.c +++ b/src/winwidget.c @@ -158,6 +158,7 @@ winwidget_create_window(winwidget ret, int h) { XSetWindowAttributes attr; + XEvent ev; XClassHint *xch; MWMHints mwmhints; Atom prop = None; @@ -256,6 +257,22 @@ winwidget_create_window(winwidget ret, XChangeProperty(disp, ret->win, prop, prop, 32, PropModeReplace, (unsigned char *) &mwmhints, PROP_MWM_HINTS_ELEMENTS); } + if (ret->full_screen) { + Atom prop_fs = XInternAtom(disp, "_NET_WM_STATE_FULLSCREEN", False); + Atom prop_state = XInternAtom(disp, "_NET_WM_STATE", False); + + memset(&ev, 0, sizeof(ev)); + ev.xclient.type = ClientMessage; + ev.xclient.message_type = prop_state; + ev.xclient.display = disp; + ev.xclient.window = ret->win; + ev.xclient.format = 32; + ev.xclient.data.l[0] = (ret->full_screen ? 1 : 0); + ev.xclient.data.l[1] = prop_fs; + + XChangeProperty(disp, ret->win, prop_state, XA_ATOM, 32, + PropModeReplace, &prop_fs, 1); + } XSetWMProtocols(disp, ret->win, &wmDeleteWindow, 1); winwidget_update_title(ret); |