We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5266f35 commit fb0fc46Copy full SHA for fb0fc46
MaterialDesignThemes.Wpf/Transitions/TransitioningContentBase.cs
@@ -131,7 +131,7 @@ private FrameworkElement GetNameScopeRoot()
131
{
132
//https://github.com/ButchersBoy/MaterialDesignInXamlToolkit/issues/950
133
//Only set the NameScope if the child does not already have a TemplateNameScope set
134
- if (GetVisualChild(0) is FrameworkElement fe && NameScope.GetNameScope(fe) != null)
+ if (VisualChildrenCount > 0 && GetVisualChild(0) is FrameworkElement fe && NameScope.GetNameScope(fe) != null)
135
136
return fe;
137
}
0 commit comments