Exemple #1
0
        public static T GetCustomAttribute <T>(this XamlType type) where T : Attribute
        {
            if (type.UnderlyingType == null)
            {
                return(null);
            }

            var ret = type.GetCustomAttributeProvider().GetCustomAttribute <T>(true);

            return(ret ?? type.BaseType?.GetCustomAttribute <T>());
        }