aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Ewmh.cc9
-rw-r--r--src/Gnome.cc11
-rw-r--r--src/Gnome.hh2
3 files changed, 21 insertions, 1 deletions
diff --git a/src/Ewmh.cc b/src/Ewmh.cc
index afa138c..be4e81a 100644
--- a/src/Ewmh.cc
+++ b/src/Ewmh.cc
@@ -369,8 +369,17 @@ void Ewmh::updateFocusedWindow(BScreen &screen, Window win) {
369 (unsigned char *)&win, 1); 369 (unsigned char *)&win, 1);
370} 370}
371 371
372// EWMH says, regarding _NET_WM_STATE and _NET_WM_DESKTOP
373// The Window Manager should remove the property whenever a window is withdrawn
374// but it should leave the property in place when it is shutting down
372void Ewmh::updateClientClose(WinClient &winclient){ 375void Ewmh::updateClientClose(WinClient &winclient){
373 updateClientList(winclient.screen()); 376 updateClientList(winclient.screen());
377 if (!winclient.screen().isShuttingdown()) {
378 XDeleteProperty(FbTk::App::instance()->display(), winclient.window(),
379 m_net_wm_state);
380 XDeleteProperty(FbTk::App::instance()->display(), winclient.window(),
381 m_net_wm_desktop);
382 }
374} 383}
375 384
376void Ewmh::updateClientList(BScreen &screen) { 385void Ewmh::updateClientList(BScreen &screen) {
diff --git a/src/Gnome.cc b/src/Gnome.cc
index c401f1b..94ff9e7 100644
--- a/src/Gnome.cc
+++ b/src/Gnome.cc
@@ -215,6 +215,17 @@ void Gnome::updateClientList(BScreen &screen) {
215 delete[] wl; 215 delete[] wl;
216} 216}
217 217
218void Gnome::updateClientClose(WinClient &client) {
219 if (client.screen().isShuttingdown()) {
220 XDeleteProperty(FbTk::App::instance()->display(), client.window(),
221 m_gnome_wm_win_workspace);
222 XDeleteProperty(FbTk::App::instance()->display(), client.window(),
223 m_gnome_wm_win_layer);
224 XDeleteProperty(FbTk::App::instance()->display(), client.window(),
225 m_gnome_wm_win_state);
226 }
227}
228
218void Gnome::updateWorkspaceNames(BScreen &screen) { 229void Gnome::updateWorkspaceNames(BScreen &screen) {
219 230
220 size_t number_of_desks = screen.getWorkspaceNames().size(); 231 size_t number_of_desks = screen.getWorkspaceNames().size();
diff --git a/src/Gnome.hh b/src/Gnome.hh
index 3325e2f..2b07fab 100644
--- a/src/Gnome.hh
+++ b/src/Gnome.hh
@@ -72,6 +72,7 @@ public:
72 void updateWorkarea(BScreen &) { } 72 void updateWorkarea(BScreen &) { }
73 void updateFocusedWindow(BScreen &, Window) { } 73 void updateFocusedWindow(BScreen &, Window) { }
74 void updateClientList(BScreen &screen); 74 void updateClientList(BScreen &screen);
75 void updateClientClose(WinClient &winclient);
75 void updateWorkspaceNames(BScreen &screen); 76 void updateWorkspaceNames(BScreen &screen);
76 void updateCurrentWorkspace(BScreen &screen); 77 void updateCurrentWorkspace(BScreen &screen);
77 void updateWorkspaceCount(BScreen &screen); 78 void updateWorkspaceCount(BScreen &screen);
@@ -85,7 +86,6 @@ public:
85 86
86 // ignore these ones 87 // ignore these ones
87 void updateFrameClose(FluxboxWindow &win) {} 88 void updateFrameClose(FluxboxWindow &win) {}
88 void updateClientClose(WinClient &winclient) {}
89 bool propertyNotify(WinClient &winclient, Atom the_property); 89 bool propertyNotify(WinClient &winclient, Atom the_property);
90 90
91private: 91private: