Only remove the initial window if no startup session is configured

This commit is contained in:
pagedown 2022-02-06 18:58:52 +08:00
parent 7740bc138b
commit 648bff02b5
No known key found for this signature in database
GPG Key ID: E921CF18AC8FF6EB

View File

@ -2256,7 +2256,7 @@ class Boss:
else:
w = None
needs_window_replaced = False
if not no_replace_window:
if not no_replace_window and not get_options().startup_session:
if w is not None and w.id == 1 and monotonic() - w.started_at < 2 and len(tuple(self.all_windows)) == 1:
# first window, soon after startup replace it
needs_window_replaced = True