internal static bool PropertyChanged <TOwner, TMember>( Expression <Func <TMember> > expression, PropertyChangedEventArgs e, bool targetPropertyOnly) { var body = expression.Body as MemberExpression; if (body == null) { throw new ArgumentException("The expression must target a property or field.", "expression"); } return(PropertyChangedExt.PropertyChanged(body, typeof(TOwner), e, targetPropertyOnly)); }
private static bool PropertyChanged(MemberExpression expression, Type ownerType, PropertyChangedEventArgs e, bool targetPropertyOnly) { var propertyName = PropertyChangedExt.GetPropertyName(expression, ownerType); return(PropertyChangedExt.PropertyChanged(propertyName, e, targetPropertyOnly)); }