窗口移动时的WPF事件
问题描述:
在WPF中是否存在一个事件,该事件在移动窗口时触发? LayoutUpdated将触发,但始终触发,如果我只想在移动窗口时才执行某项操作,而该操作过于昂贵而无法不断执行该怎么办?
Is there an event in WPF that fires when a window is moved ? LayoutUpdated will fire, but it fires ALL the time, what if I want to do something only when the window is moved that is too expensive to just do constantly ?
答
该事件已重命名为"LocationChanged".因为,我想,保持相同的名称只会使事情太容易使用.
The event has been renamed to ''LocationChanged''. Because, I guess, keeping the same names just makes things too easy to use.