Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

WidgetView.EndUpdateAnimation() Method

In This Article

Unlocks this WidgetView and animates all changes executed to its layout.

Namespace: DevExpress.XtraBars.Docking2010.Views.Widget

Assembly: DevExpress.XtraBars.v24.2.dll

NuGet Package: DevExpress.Win.Navigation

#Declaration

public void EndUpdateAnimation()

#Remarks

WidgetView supports document animation, played when documents are moved or maximized/restored. If you make adjustments to your WidgetView layout in code that include widget re-arrangement, wrap this piece of code with the WidgetView.BeginUpdateAnimation and EndUpdateAnimation methods. This will prevent the animation from being played for every minor change and instead, display one animation for the final layout version.

For example, the following code moves all widgets from stackGroup1 to stackGroup2, one at a time. Once the stackGroup1 is empty, an end-user sees all widgets moving at once, which is followed by an animation.

private void barButtonItem1_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e) {
    widgetView1.BeginUpdateAnimation();
    while (stackGroup1.Items.Count != 0) {
        Document moveDoc = stackGroup1.Items[0];
        stackGroup1.Items.Remove(moveDoc);
        stackGroup2.Items.Add(moveDoc);
    }
    widgetView1.EndUpdateAnimation();
}
See Also