From: Dana Jansens Date: Fri, 19 Jul 2002 06:56:00 +0000 (+0000) Subject: only focus new transient windows if their parent has the input focus X-Git-Url: https://git.brokenzipper.com/gitweb?a=commitdiff_plain;h=23da937e01a72cbb7af5108b9620d58cc216d731;p=chaz%2Fopenbox only focus new transient windows if their parent has the input focus --- diff --git a/src/Window.cc b/src/Window.cc index 4c7a31d7..2eaa6a67 100644 --- a/src/Window.cc +++ b/src/Window.cc @@ -2514,7 +2514,8 @@ void BlackboxWindow::mapRequestEvent(const XMapRequestEvent *re) { if (isNormal()) { if (! blackbox->isStartup()) { XSync(blackbox->getXDisplay(), False); // make sure the frame is mapped - if (isTransient() || screen->doFocusNew()) { + if (screen->doFocusNew()|| (isTransient() && getTransientFor() && + getTransientFor()->isFocused())) { setInputFocus(); } if (screen->getPlacementPolicy() == BScreen::ClickMousePlacement) {