summaryrefslogtreecommitdiff
path: root/src/screen.cc
diff options
context:
space:
mode:
authorDana Jansens <danakj@orodu.net>2003-01-07 09:30:00 +0000
committerDana Jansens <danakj@orodu.net>2003-01-07 09:30:00 +0000
commit6062fe404ce5f2505494132d5454370d696625ca (patch)
tree36c73bd4e97415ce4570b3801b49786e257e754b /src/screen.cc
parentf1ce4e660fe96816a699a89746a6105eca09babd (diff)
handle unmaps better. all thanks to acroread sending wacky unmap events
Diffstat (limited to 'src/screen.cc')
-rw-r--r--src/screen.cc9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/screen.cc b/src/screen.cc
index 2dcc110f..3c364b4c 100644
--- a/src/screen.cc
+++ b/src/screen.cc
@@ -459,19 +459,21 @@ void OBScreen::manageWindow(Window window)
XWMHints *wmhint;
XSetWindowAttributes attrib_set;
+ otk::OBDisplay::grab();
+
// is the window a docking app
if ((wmhint = XGetWMHints(otk::OBDisplay::display, window))) {
if ((wmhint->flags & StateHint) &&
wmhint->initial_state == WithdrawnState) {
//slit->addClient(w); // XXX: make dock apps work!
+ otk::OBDisplay::ungrab();
+
XFree(wmhint);
return;
}
XFree(wmhint);
}
- otk::OBDisplay::grab();
-
// choose the events we want to receive on the CLIENT window
attrib_set.event_mask = OBClient::event_mask;
attrib_set.do_not_propagate_mask = OBClient::no_propagate_mask;
@@ -517,12 +519,9 @@ void OBScreen::manageWindow(Window window)
Openbox::instance->addClient(client->frame->grip_left(), client);
Openbox::instance->addClient(client->frame->grip_right(), client);
- bool shown = false;
-
// if on the current desktop.. (or all desktops)
if (client->desktop() == _desktop ||
client->desktop() == (signed)0xffffffff) {
- shown = true;
client->frame->show();
}