public static LightDictionaryBase <string, object> GetOrAddAttachedValues(NotifyPropertyChangedBase model, bool addNew)
 {
     if (addNew && model.AttachedValues == null)
     {
         Interlocked.CompareExchange(ref model.AttachedValues, new AttachedValueDictionary(), null);
     }
     return(model.AttachedValues);
 }
Exemple #2
0
        public static void ClearAttachedValues(NotifyPropertyChangedBase model)
        {
            var values = model.AttachedValues;

            if (values != null)
            {
                values.Clear();
            }
        }
 public static void ClearAttachedValues(NotifyPropertyChangedBase model)
 {
     model.AttachedValues?.Clear();
 }
Exemple #4
0
            // *** Static Methods ***

            public static string GetPropertyName(Expression <Func <TestableNotifyPropertyChanged, object> > propertyExpression)
            {
                return(NotifyPropertyChangedBase.GetPropertyName(propertyExpression));
            }