Fixes #533
The problem was that the code was always executed. While it *attaches* the new
container to the workspace container, it also sets current = NULL and thus
always appends the container instead of inserting it after the currently
focused child. So now, we just don’t execute that code at all for
workspace_layout == default.
* workspace or a new split container with the configured
* workspace_layout).
*/
- if (con->window != NULL && parent->type == CT_WORKSPACE) {
+ if (con->window != NULL &&
+ parent->type == CT_WORKSPACE &&
+ config.default_layout != L_DEFAULT) {
DLOG("Parent is a workspace. Applying default layout...\n");
Con *target = workspace_attach_to(parent);