本文介绍了DeferWindowPos与VCL是否兼容?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在考虑增加DeferWindowPos的使用量。到目前为止,我仅在一些简单的情况下使用过它,没有发现任何问题。您是否知道任何陷阱,例如FLeft / FTop / ...字段未正确更新或类似的东西?

I'm considering to increase my usage of DeferWindowPos. Up to now I used it in some simple circumstances and didn't notice any problems. Do you know of any pitfalls, where e.g. the FLeft/FTop/... fields aren't updated correctly or similar things?

推荐答案

DeferWindowPos应该不是问题因为在完成移动/调整大小后仍发送WM_WINDOWPOSCHANGED,WM_MOVE和WM_SIZE消息。 DeferWindowPos就像用户移动窗口或调整窗口大小一样,VCL会跟踪所有更改并正确更新FLeft,FTop,FWidth和FHeight。

DeferWindowPos should't be a problem because the WM_WINDOWPOSCHANGED, WM_MOVE and WM_SIZE messages are still sent after the move/resize is finished. DeferWindowPos works as if the user moves or resized the window and the VCL keeps track of all the changes and updates FLeft, FTop, FWidth and FHeight properly.

这篇关于DeferWindowPos与VCL是否兼容?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-21 04:10