Skip to content

Commit

Permalink
Fix tearout with startupActions set. (#16089)
Browse files Browse the repository at this point in the history
Wow our preview population must just not use `startupActions`. This
obviously never worked in 1.18 Preview.

Closes #16050

(cherry picked from commit f6425db)
Service-Card-Id: 90715243
Service-Version: 1.19
  • Loading branch information
zadjii-msft authored and DHowett committed Oct 3, 2023
1 parent b9cbf0f commit 47728dc
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/cascadia/TerminalApp/TerminalWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,12 @@ namespace winrt::TerminalApp::implementation
// Pay attention, that even if some command line arguments were parsed (like launch mode),
// we will not use the startup actions from settings.
// While this simplifies the logic, we might want to reconsider this behavior in the future.
if (!_hasCommandLineArguments && _gotSettingsStartupActions)
//
// Obviously, don't use the `startupActions` from the settings in the
// case of a tear-out / reattach. GH#16050
if (!_hasCommandLineArguments &&
_initialContentArgs.empty() &&
_gotSettingsStartupActions)
{
_root->SetStartupActions(_settingsStartupArgs);
}
Expand Down

0 comments on commit 47728dc

Please sign in to comment.