Esempio n. 1
0
 public static void SetValueNoCallback(this DependencyObject obj, DependencyProperty property, object value)
 {
     ExtensionProperties.SetAreHandlersSuspended(obj, true);
     try
     {
         obj.SetValue(property, value);
     }
     finally
     {
         ExtensionProperties.SetAreHandlersSuspended(obj, false);
     }
 }
Esempio n. 2
0
 /// <summary>
 /// Determines if handlers are suspended.
 /// </summary>
 /// <param name="obj">DependencyObject</param>
 /// <returns>true/false</returns>
 public static bool AreHandlersSuspended(this DependencyObject obj)
 {
     return(ExtensionProperties.GetAreHandlersSuspended(obj));
 }