Exemple #1
0
        private static UncheckedBehavior GetOrCreateBehavior(CheckBox element)
        {
            var behavior = element.GetValue(UncheckedBehaviorProperty) as UncheckedBehavior;

            if (behavior == null)
            {
                behavior = new UncheckedBehavior(element);
                element.SetValue(UncheckedBehaviorProperty, behavior);
            }

            return(behavior);
        }
Exemple #2
0
 public static void SetUncheckedBehavior(DependencyObject obj,
                                         UncheckedBehavior value)
 {
     obj.SetValue(UncheckedBehaviorProperty, value);
 }