aboutsummaryrefslogtreecommitdiff
path: root/src/Screen.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/Screen.cc')
-rw-r--r--src/Screen.cc18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/Screen.cc b/src/Screen.cc
index 22b41dd..d2117ff 100644
--- a/src/Screen.cc
+++ b/src/Screen.cc
@@ -329,6 +329,7 @@ BScreen::BScreen(FbTk::ResourceManager &rm,
329 m_focus_control(new FocusControl(*this)), 329 m_focus_control(new FocusControl(*this)),
330 m_placement_strategy(new ScreenPlacement(*this)), 330 m_placement_strategy(new ScreenPlacement(*this)),
331 m_xinerama_headinfo(0), 331 m_xinerama_headinfo(0),
332 m_restart(false),
332 m_shutdown(false) { 333 m_shutdown(false) {
333 334
334 335
@@ -354,6 +355,19 @@ BScreen::BScreen(FbTk::ResourceManager &rm,
354 return; 355 return;
355 } 356 }
356 357
358 // check if we're the first EWMH compliant window manager on this screen
359 Atom wm_check = XInternAtom(disp, "_NET_SUPPORTING_WM_CHECK", False);
360 Atom xa_ret_type;
361 int ret_format;
362 unsigned long ret_nitems, ret_bytes_after;
363 unsigned char *ret_prop;
364 if (XGetWindowProperty(disp, m_root_window.window(), wm_check, 0l, 1l,
365 False, XA_WINDOW, &xa_ret_type, &ret_format, &ret_nitems,
366 &ret_bytes_after, &ret_prop) == Success) {
367 m_restart = (ret_prop != NULL);
368 XFree(ret_prop);
369 }
370
357 // TODO fluxgen: check if this is the right place 371 // TODO fluxgen: check if this is the right place
358 m_head_areas = new HeadArea[numHeads() ? numHeads() : 1]; 372 m_head_areas = new HeadArea[numHeads() ? numHeads() : 1];
359 373
@@ -535,6 +549,10 @@ BScreen::~BScreen() {
535 549
536} 550}
537 551
552bool BScreen::isRestart() {
553 return Fluxbox::instance()->isStartup() && m_restart;
554}
555
538void BScreen::initWindows() { 556void BScreen::initWindows() {
539 unsigned int nchild; 557 unsigned int nchild;
540 Window r, p, *children; 558 Window r, p, *children;