Table of Contents

Class ChangePropertyAction

Namespace
HeBianGu.Base.WpfBase
Assembly
HeBianGu.Base.WpfBase.dll

An action that will change a specified property to a specified value when invoked.

public class ChangePropertyAction : TargetedTriggerAction<object>, IAnimatable, IAttachedObject
Inheritance
ChangePropertyAction
Implements
Derived
Inherited Members
Extension Methods

Constructors

ChangePropertyAction()

Initializes a new instance of the ChangePropertyAction class.

public ChangePropertyAction()

Fields

DurationProperty

public static readonly DependencyProperty DurationProperty

Field Value

DependencyProperty

IncrementProperty

public static readonly DependencyProperty IncrementProperty

Field Value

DependencyProperty

PropertyNameProperty

public static readonly DependencyProperty PropertyNameProperty

Field Value

DependencyProperty

ValueProperty

public static readonly DependencyProperty ValueProperty

Field Value

DependencyProperty

Properties

Duration

Gets or sets the duration of the animation that will occur when the ChangePropertyAction is invoked. This is a dependency property. If the duration is unset, no animation will be applied.

public Duration Duration { get; set; }

Property Value

Duration

Increment

Increment by Value if true; otherwise, set the value directly. If the property cannot be incremented, it will instead try to set the value directly.

public bool Increment { get; set; }

Property Value

bool

PropertyName

Gets or sets the name of the property to change. This is a dependency property.

public string PropertyName { get; set; }

Property Value

string

The name of the property to change.

Value

Gets or sets the value to set. This is a dependency property.

public object Value { get; set; }

Property Value

object

The value to set.

Methods

Invoke(object)

Invokes the action.

protected override void Invoke(object parameter)

Parameters

parameter object

The parameter of the action. If the action does not require a parameter, then the parameter may be set to a null reference.

Exceptions

ArgumentException

A property with could not be found on the Target.

ArgumentException

Could not set to the value specified by .

ValidateProperty(PropertyInfo)

protected void ValidateProperty(PropertyInfo propertyInfo)

Parameters

propertyInfo PropertyInfo