CloseWindow和WM_CLOSE有什么关系 [英] What is the relationship of CloseWindow and WM_CLOSE
问题描述
我目前有点困惑:是 WM_CLOSE 和 ::CloseWindow
以任何方式相关"还是用于完全不同的事物?
I'm a bit confused currently: Are WM_CLOSE and ::CloseWindow
in any way "related" or are for completely different things?
关闭Windows的文档不要提及API函数 CloseWindow
一个>. CloseWindow
应该真正被称为"MinimizeWindow"还是我遗漏的是什么?
The docs for Closing Windows don't mention the API function CloseWindow
at all. Should CloseWindow
be really called "MinimizeWindow" or what am I missing?
推荐答案
CloseWindow
和WM_CLOSE
完全无关. CloseWindow
函数的名称错误.鉴于其恢复窗口的功能,其反函数OpenWindow
的命名也与此类似.
CloseWindow
and WM_CLOSE
are completely unrelated. The CloseWindow
function is badly named. Its inverse function, OpenWindow
is similarly badly named given that it restores windows.
我怀疑这些名称的确可以追溯到很长一段时间,可能是Windows版本1或2.我推测我们现在所说的 minimize 和 restore 是,当时称为 close 和 open .
I suspect these names dates back a very long way indeed, probably to Windows version 1 or 2. I'm speculating that what we now call minimize and restore were, back then, called close and open.
最小化或还原窗口的通常方法是通过SW_MINIMIZE
或SW_RESTORE
调用ShowWindow
.
The usual way to minimize or restore a window is to call ShowWindow
passing SW_MINIMIZE
or SW_RESTORE
.
我建议您忘记有关CloseWindow
和OpenWindow
的所有信息.
I suggest that you forget all about CloseWindow
and OpenWindow
.
这篇关于CloseWindow和WM_CLOSE有什么关系的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!