Back to Devexpress

TreeListOptionsBehavior.AllowExpandAnimation Property

windowsforms-devexpress-dot-xtratreelist-dot-treelistoptionsbehavior-ba510228.md

latest4.5 KB
Original Source

TreeListOptionsBehavior.AllowExpandAnimation Property

Gets or sets whether to use animation effects when expanding/collapsing nodes using the expand button.

Namespace : DevExpress.XtraTreeList

Assembly : DevExpress.XtraTreeList.v25.2.dll

NuGet Packages : DevExpress.Win.Navigation, DevExpress.Win.TreeList

Declaration

csharp
[DefaultValue(DefaultBoolean.Default)]
[XtraSerializableProperty]
public virtual DefaultBoolean AllowExpandAnimation { get; set; }
vb
<DefaultValue(DefaultBoolean.Default)>
<XtraSerializableProperty>
Public Overridable Property AllowExpandAnimation As DefaultBoolean

Property Value

TypeDefaultDescription
DefaultBooleanDefault

True , to use animation effects; otherwise, False ; Default uses the WindowsFormsSettings.AnimationMode static (Shared in VB) setting.

|

Available values:

NameDescriptionReturn Value
True

The value is true.

|

0

| | False |

The value is false.

|

1

| | Default |

The value is specified by a global option or a higher-level object.

|

2

|

Property Paths

You can access this nested property as listed below:

Object TypePath to AllowExpandAnimation
TreeList

.OptionsBehavior .AllowExpandAnimation

|

Remarks

End-users can expand/collapse nodes using the expand button. The AllowExpandAnimation property specifies whether to use animation effects when expanding/collapsing nodes. If this property is set to Default , the actual behavior depends on the WindowsFormsSettings.AnimationMode static setting. If the global setting is set to Default or EnableAll , the animation effects are enabled; otherwise, they are disabled.

If you subscribe to the TreeList.BeforeExpand, TreeList.BeforeCollapse, TreeList.AfterExpand or TreeList.AfterCollapse event and the AllowExpandAnimation setting is Default , the expand/collapse animation effects are forcibly disabled.

In code, you can expand/collapse a node using the TreeListNode.Expand, TreeList.ExpandAll, TreeList.CollapseAll, TreeList.ExpandToLevel and TreeList.CollapseToLevel methods. When expanding/collapsing nodes in code, the animation is always disabled, regardless of the AllowExpandAnimation property value.

See Also

Expand

ExpandAll()

CollapseAll()

ExpandToLevel(Int32)

CollapseToLevel(Int32)

TreeListOptionsBehavior Class

TreeListOptionsBehavior Members

DevExpress.XtraTreeList Namespace