diff --git a/manage.cpp b/manage.cpp index f101dcedf5..4198e60436 100644 --- a/manage.cpp +++ b/manage.cpp @@ -193,8 +193,10 @@ bool Client::manage(xcb_window_t w, bool isMapped) for (auto it = mainclients.constBegin(); it != mainclients.constEnd(); ++it) { - if (mainclients.count() > 1 && (*it)->isSpecialWindow()) - continue; // Don't consider toolbars etc when placing + if (mainclients.count() > 1 && // A group-transient + (*it)->isSpecialWindow() && // Don't consider toolbars etc when placing + !(info->state() & NET::Modal)) // except when it's modal (blocks specials as well) + continue; maincl = *it; if ((*it)->isOnCurrentDesktop()) on_current = true; @@ -210,11 +212,12 @@ bool Client::manage(xcb_window_t w, bool isMapped) if (maincl) setOnActivities(maincl->activities()); + } else { // a transient shall appear on its leader and not drag that around + if (info->desktop()) + desk = info->desktop(); // Window had the initial desktop property, force it + if (desktop() == 0 && asn_valid && asn_data.desktop() != 0) + desk = asn_data.desktop(); } - if (info->desktop()) - desk = info->desktop(); // Window had the initial desktop property, force it - if (desktop() == 0 && asn_valid && asn_data.desktop() != 0) - desk = asn_data.desktop(); #ifdef KWIN_BUILD_ACTIVITIES if (Activities::self() && !isMapped && !noborder && isNormalWindow() && !activitiesDefined) { //a new, regular window, when we're not recovering from a crash,