UIElement.InvalidateArrange UIElement.InvalidateArrange UIElement.InvalidateArrange UIElement.InvalidateArrange Method

定义

使元素排列状态(布局)无效。Invalidates the arrange state (layout) for the element. 排列状态失效后,该元素将更新其布局,更新将以异步方式发生,除非随后由 UpdateLayout() 强制执行。After the invalidation, the element will have its layout updated, which will occur asynchronously unless subsequently forced by UpdateLayout().

public:
 void InvalidateArrange();
public void InvalidateArrange ();
member this.InvalidateArrange : unit -> unit
Public Sub InvalidateArrange ()

注解

频繁调用InvalidateArrange或特别是对UpdateLayout性能产生显著影响。Frequent calls to InvalidateArrange or in particular to UpdateLayout have significant performance consequences. 因此, 请避免调用此方法, 除非你绝对需要精确布局状态才能对代码APIAPIs中的其他调用进行后续调用。Therefore, avoid calling this method unless you absolutely require precise layout state for subsequent calls to other APIAPIs in your code. 如果InvalidateArrange您要PropertyChangedCallback为不在FreezableFrameworkElement派生类上的依赖属性创建, 而该属性在更改时仍会影响布局的排列处理过程, 则可能会调用的高级方案。An advanced scenario where you might call InvalidateArrange is if you are creating a PropertyChangedCallback for a dependency property that is not on a Freezable or FrameworkElement derived class that still influences the arrange pass of layout when it changes.

适用于