]> Dogcows Code - chaz/openbox/blobdiff - src/blackbox.cc
make iconified windows uniconify on an XMapRequestEvent.
[chaz/openbox] / src / blackbox.cc
index 00a640381530341f1974dacc5a92334ac9bb79fd..0865b681f6e50fb1ed330294ea55c1f3a6925d4b 100644 (file)
@@ -111,7 +111,6 @@ using std::string;
 #include "Workspace.hh"
 #include "Workspacemenu.hh"
 #include "XAtom.hh"
-#include "Input.hh"
 
 // X event scanner for enter/leave notifies - adapted from twm
 struct scanargs {
@@ -163,7 +162,6 @@ Blackbox::Blackbox(char **m_argv, char *dpy_name, char *rc, char *menu)
   load_rc();
 
   xatom = new XAtom(getXDisplay());
-  input = new BInput(this);
 
   cursor.session = XCreateFontCursor(getXDisplay(), XC_left_ptr);
   cursor.move = XCreateFontCursor(getXDisplay(), XC_fleur);
@@ -324,7 +322,12 @@ void Blackbox::process_event(XEvent *e) {
 
     BlackboxWindow *win = searchWindow(e->xmaprequest.window);
 
-    if (! win) {
+    if (win) {
+      if (win->isIconic()) {
+        win->deiconify();
+        win->setInputFocus();
+      }
+    } else {
       BScreen *screen = searchScreen(e->xmaprequest.parent);
 
       if (! screen) {
@@ -446,13 +449,9 @@ void Blackbox::process_event(XEvent *e) {
   case PropertyNotify: {
     last_time = e->xproperty.time;
 
-    if (e->xproperty.state != PropertyDelete) {
-      BlackboxWindow *win = searchWindow(e->xproperty.window);
-
-      if (win)
-        win->propertyNotifyEvent(e->xproperty.atom);
-    }
-
+    BlackboxWindow *win = searchWindow(e->xproperty.window);
+    if (win)
+      win->propertyNotifyEvent(&e->xproperty);
     break;
   }
 
This page took 0.022983 seconds and 4 git commands to generate.