예제 #1
0
        void OnInstantiated(object sender, TemplateInstantiatedEventArgs templateInstantiatedEventArgs)
        {
            if (templateInstantiatedEventArgs.Container is LayoutItemTemplateContainer layoutItemTemplateContainer)
            {
                _layoutStyleProvider.ApplyCaptionControlStyle(layoutItemTemplateContainer);
                _layoutStyleProvider.ApplyContainerControlStyle(layoutItemTemplateContainer);
            }

            if (templateInstantiatedEventArgs.Container is LayoutGroupTemplateContainer layoutGroupTemplateContainer)
            {
                _layoutStyleProvider.ApplyGroupControlStyle(layoutGroupTemplateContainer);
            }
        }
예제 #2
0
        void OnInstantiated(object sender, TemplateInstantiatedEventArgs templateInstantiatedEventArgs)
        {
            var layoutItemTemplateContainer = templateInstantiatedEventArgs.Container as LayoutItemTemplateContainer;

            if (layoutItemTemplateContainer != null)
            {
                _layoutStyleProvider.ApplyCaptionControlStyle(layoutItemTemplateContainer);
                _layoutStyleProvider.ApplyContainerControlStyle(layoutItemTemplateContainer);
            }
            var layoutGroupTemplateContainer = templateInstantiatedEventArgs.Container as LayoutGroupTemplateContainer;

            if (layoutGroupTemplateContainer != null)
            {
                _layoutStyleProvider.ApplyGroupControlStyle(layoutGroupTemplateContainer);
            }
        }