diff --git a/controls/dev/AnnotatedScrollBar/AnnotatedScrollBar.cpp b/controls/dev/AnnotatedScrollBar/AnnotatedScrollBar.cpp index cd5c0e2d70..f6c14b2480 100644 --- a/controls/dev/AnnotatedScrollBar/AnnotatedScrollBar.cpp +++ b/controls/dev/AnnotatedScrollBar/AnnotatedScrollBar.cpp @@ -299,11 +299,14 @@ void AnnotatedScrollBar::QueueLayoutLabels(unsigned int millisecondWait) if (!m_labelsDebounce.test_and_set()) { - auto strongThis = get_strong(); // ensure object lifetime during coroutines - auto runLayoutLabelsAction = [&, strongThis]() + auto weakThis = get_weak(); + auto runLayoutLabelsAction = [weakThis]() { - strongThis->m_labelsDebounce.clear(); - strongThis->LayoutLabels(); + if (auto strongThis = weakThis.get()) + { + strongThis->m_labelsDebounce.clear(); + strongThis->LayoutLabels(); + } }; SharedHelpers::ScheduleActionAfterWait(runLayoutLabelsAction, millisecondWait); diff --git a/controls/dev/CommandBarFlyout/CommandBarFlyout_themeresources.xaml b/controls/dev/CommandBarFlyout/CommandBarFlyout_themeresources.xaml index 7117e4e27f..01c44209c1 100644 --- a/controls/dev/CommandBarFlyout/CommandBarFlyout_themeresources.xaml +++ b/controls/dev/CommandBarFlyout/CommandBarFlyout_themeresources.xaml @@ -310,7 +310,7 @@ - \ No newline at end of file + diff --git a/controls/dev/CommonStyles/TestUI/CommonStylesPage.xaml b/controls/dev/CommonStyles/TestUI/CommonStylesPage.xaml index 93c579a5c8..84ee172d61 100644 --- a/controls/dev/CommonStyles/TestUI/CommonStylesPage.xaml +++ b/controls/dev/CommonStyles/TestUI/CommonStylesPage.xaml @@ -293,6 +293,20 @@ + + + + + + + + + +