Пример #1
0
 public static void SetInstance(DependencyObject element, StyleService value)
 {
     element.SetValue(InstanceProperty, value);
 }
Пример #2
0
 internal StyleBase()
 {
     StyleService = new StyleService(this);
 }
Пример #3
0
        private static void OnInstanceChanged(DependencyObject fre, StyleService oldStyleService, StyleService newStyleService)
        {
            if (oldStyleService != null)
            {
                fre.RemoveService <Runtime>();
            }

            if (newStyleService != null)
            {
                fre.SetService(new Runtime(newStyleService));
            }
        }