VirtualBox

source: vbox/trunk/src/VBox/Additions/WINNT/Graphics/Wine/include/powrprof.h@ 16410

最後變更 在這個檔案從16410是 16410,由 vboxsync 提交於 16 年 前

export the Wine stuff to OSE

  • 屬性 svn:eol-style 設為 native
檔案大小: 4.6 KB
 
1/*
2 * Copyright (C) 2005 Benjamin Cutler
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17 */
18
19#ifndef __WINE_POWRPROF_H
20#define __WINE_POWRPROF_H 1
21
22#define EnableSysTrayBatteryMeter 0x01
23#define EnableMultiBatteryDisplay 0x02
24#define EnablePasswordLogon 0x04
25#define EnableWakeOnRing 0x08
26#define EnableVideoDimDisplay 0x10
27
28typedef struct _GLOBAL_MACHINE_POWER_POLICY {
29 ULONG Revision;
30 SYSTEM_POWER_STATE LidOpenWakeAc;
31 SYSTEM_POWER_STATE LidOpenWakeDc;
32 ULONG BroadcastCapacityResolution;
33} GLOBAL_MACHINE_POWER_POLICY,
34*PGLOBAL_MACHINE_POWER_POLICY;
35
36typedef struct _GLOBAL_USER_POWER_POLICY {
37 ULONG Revision;
38 POWER_ACTION_POLICY PowerButtonAc;
39 POWER_ACTION_POLICY PowerButtonDc;
40 POWER_ACTION_POLICY SleepButtonAc;
41 POWER_ACTION_POLICY SleepButtonDc;
42 POWER_ACTION_POLICY LidCloseAc;
43 POWER_ACTION_POLICY LidCloseDc;
44 SYSTEM_POWER_LEVEL DischargePolicy[NUM_DISCHARGE_POLICIES];
45 ULONG GlobalFlags;
46} GLOBAL_USER_POWER_POLICY,
47*PGLOBAL_USER_POWER_POLICY;
48
49typedef struct _GLOBAL_POWER_POLICY {
50 GLOBAL_USER_POWER_POLICY user;
51 GLOBAL_MACHINE_POWER_POLICY mach;
52} GLOBAL_POWER_POLICY,
53*PGLOBAL_POWER_POLICY;
54
55typedef struct _MACHINE_POWER_POLICY {
56 ULONG Revision;
57 SYSTEM_POWER_STATE MinSleepAc;
58 SYSTEM_POWER_STATE MinSleepDc;
59 SYSTEM_POWER_STATE ReducedLatencySleepAc;
60 SYSTEM_POWER_STATE ReducedLatencySleepDc;
61 ULONG DozeTimeoutAc;
62 ULONG DozeTimeoutDc;
63 ULONG DozeS4TimeoutAc;
64 ULONG DozeS4TimeoutDc;
65 UCHAR MinThrottleAc;
66 UCHAR MinThrottleDc;
67 UCHAR pad1[2];
68 POWER_ACTION_POLICY OverThrottledAc;
69 POWER_ACTION_POLICY OverThrottledDc;
70} MACHINE_POWER_POLICY,
71*PMACHINE_POWER_POLICY;
72
73typedef struct _MACHINE_PROCESSOR_POWER_POLICY {
74 ULONG Revision;
75 PROCESSOR_POWER_POLICY ProcessorPolicyAc;
76 PROCESSOR_POWER_POLICY ProcessorPolicyDc;
77} MACHINE_PROCESSOR_POWER_POLICY,
78*PMACHINE_PROCESSOR_POWER_POLICY;
79
80typedef struct _USER_POWER_POLICY {
81 ULONG Revision;
82 POWER_ACTION_POLICY IdleAc;
83 POWER_ACTION_POLICY IdleDc;
84 ULONG IdleTimeoutAc;
85 ULONG IdleTimeoutDc;
86 UCHAR IdleSensitivityAc;
87 UCHAR IdleSensitivityDc;
88 UCHAR ThrottlePolicyAc;
89 UCHAR ThrottlePolicyDc;
90 SYSTEM_POWER_STATE MaxSleepAc;
91 SYSTEM_POWER_STATE MaxSleepDc;
92 ULONG Reserved[2];
93 ULONG VideoTimeoutAc;
94 ULONG VideoTimeoutDc;
95 ULONG SpindownTimeoutAc;
96 ULONG SpindownTimeoutDc;
97 BOOLEAN OptimizeForPowerAc;
98 BOOLEAN OptimizeForPowerDc;
99 UCHAR FanThrottleToleranceAc;
100 UCHAR FanThrottleToleranceDc;
101 UCHAR ForcedThrottleAc;
102 UCHAR ForcedThrottleDc;
103} USER_POWER_POLICY,
104*PUSER_POWER_POLICY;
105
106typedef struct _POWER_POLICY {
107 USER_POWER_POLICY user;
108 MACHINE_POWER_POLICY mach;
109} POWER_POLICY,
110*PPOWER_POLICY;
111
112
113#ifdef __cplusplus
114extern "C" {
115#endif
116
117typedef BOOLEAN (CALLBACK* PWRSCHEMESENUMPROC)(UINT, DWORD, LPWSTR, DWORD, LPWSTR, PPOWER_POLICY, LPARAM);
118
119NTSTATUS WINAPI CallNtPowerInformation(POWER_INFORMATION_LEVEL, PVOID, ULONG, PVOID, ULONG);
120BOOLEAN WINAPI CanUserWritePwrScheme(VOID);
121BOOLEAN WINAPI DeletePwrScheme(UINT);
122BOOLEAN WINAPI EnumPwrSchemes(PWRSCHEMESENUMPROC, LPARAM);
123BOOLEAN WINAPI GetActivePwrScheme(PUINT);
124BOOLEAN WINAPI GetCurrentPowerPolicies(PGLOBAL_POWER_POLICY, PPOWER_POLICY);
125BOOLEAN WINAPI GetPwrCapabilities(PSYSTEM_POWER_CAPABILITIES);
126BOOLEAN WINAPI GetPwrDiskSpindownRange(PUINT, PUINT);
127BOOLEAN WINAPI IsAdminOverrideActive(PADMINISTRATOR_POWER_POLICY);
128BOOLEAN WINAPI IsPwrHibernateAllowed(VOID);
129BOOLEAN WINAPI IsPwrShutdownAllowed(VOID);
130BOOLEAN WINAPI IsPwrSuspendAllowed(VOID);
131BOOLEAN WINAPI ReadGlobalPwrPolicy(PGLOBAL_POWER_POLICY);
132BOOLEAN WINAPI ReadProcessorPwrScheme(UINT, PMACHINE_PROCESSOR_POWER_POLICY);
133BOOLEAN WINAPI ReadPwrScheme(UINT, PPOWER_POLICY);
134BOOLEAN WINAPI SetActivePwrScheme(UINT, PGLOBAL_POWER_POLICY, PPOWER_POLICY);
135BOOLEAN WINAPI SetSuspendState(BOOLEAN, BOOLEAN, BOOLEAN);
136BOOLEAN WINAPI WriteGlobalPwrPolicy(PGLOBAL_POWER_POLICY);
137BOOLEAN WINAPI WriteProcessorPwrScheme(UINT, PMACHINE_PROCESSOR_POWER_POLICY);
138BOOLEAN WINAPI WritePwrScheme(PUINT, LPWSTR, LPWSTR, PPOWER_POLICY);
139
140#ifdef __cplusplus
141}
142#endif
143
144#endif /* _POWRPROF_H */
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette