aboutsummaryrefslogtreecommitdiff
path: root/src/Ewmh.cc
diff options
context:
space:
mode:
authormarkt <markt>2006-08-10 06:35:14 (GMT)
committermarkt <markt>2006-08-10 06:35:14 (GMT)
commit839cc974c15381de184f7f6c51821784709ef99d (patch)
tree85ea363a3d91e0aefaedb955c00e4c7584d93822 /src/Ewmh.cc
parentb6bbc37c1edc7ea3b4de3ad9393853e4704080a2 (diff)
downloadfluxbox-839cc974c15381de184f7f6c51821784709ef99d.zip
fluxbox-839cc974c15381de184f7f6c51821784709ef99d.tar.bz2
implement _NET_WM_WINDOW_TYPE_MENU AND _NET_WM_WINDOW_TYPE_TOOLBAR
Diffstat (limited to 'src/Ewmh.cc')
-rw-r--r--src/Ewmh.cc19
1 files changed, 16 insertions, 3 deletions
diff --git a/src/Ewmh.cc b/src/Ewmh.cc
index 97c66b8..cb9f0f6 100644
--- a/src/Ewmh.cc
+++ b/src/Ewmh.cc
@@ -144,6 +144,8 @@ void Ewmh::initForScreen(BScreen &screen) {
144 m_net_wm_window_type_desktop, 144 m_net_wm_window_type_desktop,
145 m_net_wm_window_type_splash, 145 m_net_wm_window_type_splash,
146 m_net_wm_window_type_dialog, 146 m_net_wm_window_type_dialog,
147 m_net_wm_window_type_menu,
148 m_net_wm_window_type_toolbar,
147 m_net_wm_window_type_normal, 149 m_net_wm_window_type_normal,
148 150
149 // window actions 151 // window actions
@@ -300,8 +302,19 @@ void Ewmh::setupFrame(FluxboxWindow &win) {
300 } else if (atoms[l] == m_net_wm_window_type_dialog) { 302 } else if (atoms[l] == m_net_wm_window_type_dialog) {
301 // dialog windows should not be tabable 303 // dialog windows should not be tabable
302 win.setTabable(false); 304 win.setTabable(false);
305 } else if (atoms[l] == m_net_wm_window_type_menu ||
306 atoms[l] == m_net_wm_window_type_toolbar) {
307 /*
308 * _NET_WM_WINDOW_TYPE_TOOLBAR and _NET_WM_WINDOW_TYPE_MENU
309 * indicate toolbar and pinnable menu windows, respectively
310 * (i.e. toolbars and menus "torn off" from the main
311 * application). Windows of this type may set the
312 * WM_TRANSIENT_FOR hint indicating the main application window.
313 */
314 win.setDecoration(FluxboxWindow::DECOR_NONE);
315 win.setIconHidden(true);
316 win.moveToLayer(Layer::ABOVE_DOCK);
303 } 317 }
304
305 } 318 }
306 XFree(data); 319 XFree(data);
307 } else { 320 } else {
@@ -317,8 +330,6 @@ void Ewmh::setupFrame(FluxboxWindow &win) {
317 330
318 /* 331 /*
319 * NOT YET IMPLEMENTED: 332 * NOT YET IMPLEMENTED:
320 * _NET_WM_WINDOW_TYPE_TOOLBAR
321 * _NET_WM_WINDOW_TYPE_MENU
322 * _NET_WM_WINDOW_TYPE_UTILITY 333 * _NET_WM_WINDOW_TYPE_UTILITY
323 */ 334 */
324 335
@@ -971,6 +982,8 @@ void Ewmh::createAtoms() {
971 m_net_wm_window_type_desktop = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_DESKTOP", False); 982 m_net_wm_window_type_desktop = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_DESKTOP", False);
972 m_net_wm_window_type_splash = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_SPLASH", False); 983 m_net_wm_window_type_splash = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_SPLASH", False);
973 m_net_wm_window_type_dialog = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_DIALOG", False); 984 m_net_wm_window_type_dialog = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_DIALOG", False);
985 m_net_wm_window_type_menu = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_MENU", False);
986 m_net_wm_window_type_toolbar = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_TOOLBAR", False);
974 m_net_wm_window_type_normal = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_NORMAL", False); 987 m_net_wm_window_type_normal = XInternAtom(disp, "_NET_WM_WINDOW_TYPE_NORMAL", False);
975 988
976 // state atom and the supported state atoms 989 // state atom and the supported state atoms