@@ -220,12 +220,7 @@ namespace winrt::TerminalApp::implementation
220
220
_root->Initialized ({ get_weak (), &TerminalWindow::_pageInitialized });
221
221
_root->WindowSizeChanged ({ get_weak (), &TerminalWindow::_WindowSizeChanged });
222
222
_root->RenameWindowRequested ({ get_weak (), &TerminalWindow::_RenameWindowRequested });
223
- _root->ShowLoadWarningsDialog ([weakThis{ get_weak () }](auto && /* s*/ , const Windows::Foundation::Collections::IVectorView<Microsoft::Terminal::Settings::Model::SettingsLoadWarnings>& warnings) {
224
- if (auto strongThis{ weakThis.get () })
225
- {
226
- strongThis->_ShowLoadWarningsDialog (warnings);
227
- }
228
- });
223
+ _root->ShowLoadWarningsDialog ({ get_weak (), &TerminalWindow::_ShowLoadWarningsDialog });
229
224
_root->Create ();
230
225
231
226
AppLogic::Current ()->SettingsChanged ({ get_weak (), &TerminalWindow::UpdateSettingsHandler });
@@ -484,7 +479,7 @@ namespace winrt::TerminalApp::implementation
484
479
// validating the settings.
485
480
// - Only one dialog can be visible at a time. If another dialog is visible
486
481
// when this is called, nothing happens. See ShowDialog for details
487
- void TerminalWindow::_ShowLoadWarningsDialog (const Windows::Foundation::Collections::IVectorView<SettingsLoadWarnings>& warnings)
482
+ void TerminalWindow::_ShowLoadWarningsDialog (const IInspectable&, const Windows::Foundation::Collections::IVectorView<SettingsLoadWarnings>& warnings)
488
483
{
489
484
auto title = RS_ (L" SettingsValidateErrorTitle" );
490
485
auto buttonText = RS_ (L" Ok" );
@@ -545,7 +540,7 @@ namespace winrt::TerminalApp::implementation
545
540
}
546
541
else if (settingsLoadedResult == S_FALSE)
547
542
{
548
- _ShowLoadWarningsDialog (_initialLoadResult.Warnings ());
543
+ _ShowLoadWarningsDialog (nullptr , _initialLoadResult.Warnings ());
549
544
}
550
545
}
551
546
@@ -831,7 +826,7 @@ namespace winrt::TerminalApp::implementation
831
826
}
832
827
else if (args.Result () == S_FALSE)
833
828
{
834
- _ShowLoadWarningsDialog (args.Warnings ());
829
+ _ShowLoadWarningsDialog (nullptr , args.Warnings ());
835
830
}
836
831
else if (args.Result () == S_OK)
837
832
{
0 commit comments