Exemplo n.º 1
0
 public static void CopyPropertiesTo(object instance, KeyValuePair <AttachableMemberIdentifier, object>[] array, int index)
 {
     if (instance != null)
     {
         IAttachedPropertyStore store = instance as IAttachedPropertyStore;
         if (store != null)
         {
             store.CopyPropertiesTo(array, index);
         }
         else
         {
             attachedProperties.CopyPropertiesTo(instance, array, index);
         }
     }
 }
Exemplo n.º 2
0
        public static void CopyPropertiesTo(object instance, KeyValuePair <AttachableMemberIdentifier, object>[] array, int index)
        {
            if (instance == null)
            {
                return;
            }

            IAttachedPropertyStore ap = instance as IAttachedPropertyStore;

            if (ap != null)
            {
                ap.CopyPropertiesTo(array, index);
            }
            else
            {
                attachedProperties.CopyPropertiesTo(instance, array, index);
            }
        }