Use setMinimized() during window initialization

If setMinimized() is used during window initialization, no animation
will be played, so we could use setMinimized() instead of minimize()
that takes "avoid animation" boolean trap.
master
Vlad Zahorodnii 2 years ago
parent b53621136d
commit 84521ddb18

@ -859,9 +859,7 @@ bool X11Window::manage(xcb_window_t w, bool isMapped)
}
}
if (init_minimize) {
minimize(true); // No animation
}
setMinimized(init_minimize);
// Other settings from the previous session
if (session) {

@ -1377,9 +1377,7 @@ void XdgToplevelWindow::initialize()
setOnActivities(rules()->checkActivity(activities(), true));
setDesktops(rules()->checkDesktops(desktops(), true));
setDesktopFileName(rules()->checkDesktopFile(desktopFileName(), true));
if (rules()->checkMinimize(isMinimized(), true)) {
minimize(true); // No animation.
}
setMinimized(rules()->checkMinimize(isMinimized(), true));
setSkipTaskbar(rules()->checkSkipTaskbar(skipTaskbar(), true));
setSkipPager(rules()->checkSkipPager(skipPager(), true));
setSkipSwitcher(rules()->checkSkipSwitcher(skipSwitcher(), true));

Loading…
Cancel
Save