问题描述
在Windows 7电源管理中,有一种方法可以在笔记本电脑机盖合上时指定所需的行为(睡眠,休眠,不执行任何操作等).因此,那里的窗户必须以某种方式知道盖子正在关闭.
In windows 7 power management, there is a way to specify desired behaviors (sleep, hibernate, do nothing, etc) when the laptop lid is closed. Therefore there windows must somehow know the lid is closing.
我试图找到一种检测此类事件的方法,但是我只能在计算机进入/离开睡眠状态时才能找到拦截事件的建议.这并不是我想要的,因为我想在盖子关闭时捕获事件,无论 盖子是否会进入睡眠状态.
I tried to find a way to detect such a event, however I can only find suggestions to intercept events when the computer is entering/leaving sleep. This is not exactly what I am looking for, because I want to capture the event when the lid is closing, regardless whether or not it is going to sleep as a result of the lid closing.
任何人都可以建议要监视的正确事件吗?
Could any one suggest the correct event to monitor?
谢谢
推荐答案
GUID:GUID_LIDCLOSE_ACTION/GUID_LIDOPEN_POWERSTATE
GUID's: GUID_LIDCLOSE_ACTION/GUID_LIDOPEN_POWERSTATE
这篇关于笔记本电脑盖关闭/打开事件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!