mirror of
https://github.com/reactos/reactos.git
synced 2024-12-29 10:35:28 +00:00
181b666fc4
In order for the NT power manager to interact with the Win32 subsystem (thus the whole rest of the system), the Win32 kernel-mode subsystem provides a mechanism that communicates with the kernel power manager via power callouts (aka power requests as per Windows' PDB symbols). Such mechanism enters in action as soon as Win32 callout routines are estabilished with the PsEstablishWin32Callouts() function. The NT power manager, the power policy manager respectively, invokes a power callout to denote an exceptional phenomena as a result of power policies or capabilities changes, turning ON/OFF the display, a system time change has occurred, etc. Such scenarios are described as power events of which the NT power manager sends a WIN32_POWEREVENT_PARAMETERS packet to Win32k via the estabilished "PowerEventCallout" pointer function callout. For other callouts that inform the Win32 subsystem of impeding power state changes across the system or devices, these are sent as WIN32_POWERSTATE_PARAMETERS packets with its own separate callout. The purpose of such mechanism is to give Win32k the opportunity to do power related tasks and alert every application of such power events in accordance with what it gets notified by the NT power manager. Currently this patch stubplements this mechanism in ROS, it is only just the barebones for now. The development of the Win32 power manager will go in parallel with the kernel power manager development (expand, improve, fix the code of issues that whatever may arise). So far only the PsW32SystemTime power event is implemented for the moment being. This work was decoupled from PR #5719 to avoid clobbering it too much. === TODO === - Implement power states management communication with the kernel power manager - Implement the rest of the power events in IntHandlePowerEventWorker - Implement power event handling in CSRSS (or WinSrv?) which handles any of the events that could not be handled by Win32k otherwise - Estabilish the power state callout in PsEstablishWin32Callouts() (currently there is no a pointer function that gets assigned to such callout) CORE-18969
104 lines
2.9 KiB
C
104 lines
2.9 KiB
C
/*
|
|
* COPYRIGHT: See COPYING in the top level directory
|
|
* PROJECT: ReactOS Graphics Subsystem
|
|
* FILE: win32ss/win32kp.h
|
|
* PURPOSE: Internal Win32K Header
|
|
* PROGRAMMER: Alex Ionescu (alex@relsoft.net)
|
|
*/
|
|
|
|
/* INCLUDES ******************************************************************/
|
|
|
|
#pragma once
|
|
|
|
/* Enable debugging features */
|
|
#define GDI_DEBUG 0
|
|
#define DBG_ENABLE_GDIOBJ_BACKTRACES 0
|
|
#define DBG_ENABLE_EVENT_LOGGING 0
|
|
#define DBG_ENABLE_SERVICE_HOOKS 0
|
|
|
|
/* Internal NtGdi Headers */
|
|
typedef struct _DC *PDC;
|
|
#include "gdi/ntgdi/rect.h"
|
|
#include "gdi/ntgdi/misc.h"
|
|
#include "gdi/ntgdi/gdiobj.h"
|
|
#include "gdi/ntgdi/palette.h"
|
|
#include "gdi/eng/surface.h"
|
|
#include "gdi/eng/mdevobj.h"
|
|
#include "gdi/eng/pdevobj.h"
|
|
#include "gdi/eng/ldevobj.h"
|
|
#include "gdi/eng/device.h"
|
|
#include "gdi/eng/driverobj.h"
|
|
#include "gdi/eng/engobjects.h"
|
|
#include "gdi/eng/eng.h"
|
|
#include "gdi/eng/engevent.h"
|
|
#include "gdi/eng/inteng.h"
|
|
#include "gdi/eng/xlateobj.h"
|
|
#include "gdi/eng/floatobj.h"
|
|
#include "gdi/eng/mouse.h"
|
|
#include "gdi/eng/mapping.h"
|
|
#include "gdi/ntgdi/xformobj.h"
|
|
#include "gdi/ntgdi/brush.h"
|
|
#include "gdi/ntgdi/color.h"
|
|
#include "gdi/ntgdi/bitmaps.h"
|
|
#include "gdi/ntgdi/region.h"
|
|
#include "gdi/ntgdi/dc.h"
|
|
#include "gdi/ntgdi/dib.h"
|
|
#include "gdi/ntgdi/cliprgn.h"
|
|
#include "gdi/ntgdi/intgdi.h"
|
|
#include "gdi/ntgdi/paint.h"
|
|
#include "gdi/ntgdi/text.h"
|
|
#include "gdi/ntgdi/pen.h"
|
|
#include "gdi/ntgdi/cliprgn.h"
|
|
#include "gdi/ntgdi/coord.h"
|
|
#include "gdi/ntgdi/path.h"
|
|
#include "gdi/dib/dib.h"
|
|
#include "reactx/ntddraw/intddraw.h"
|
|
|
|
/* Internal NtUser Headers */
|
|
#include "user/ntuser/win32kdebug.h"
|
|
#include "user/ntuser/win32.h"
|
|
#include "user/ntuser/tags.h"
|
|
#ifndef __cplusplus
|
|
#include "user/ntuser/ntuser.h"
|
|
#include "user/ntuser/usrheap.h"
|
|
#include "user/ntuser/object.h"
|
|
#include "user/ntuser/shutdown.h"
|
|
#include "user/ntuser/cursoricon.h"
|
|
#include "user/ntuser/accelerator.h"
|
|
#include "user/ntuser/hook.h"
|
|
#include "user/ntuser/clipboard.h"
|
|
#include "user/ntuser/display.h"
|
|
#include "user/ntuser/winsta.h"
|
|
#include "user/ntuser/msgqueue.h"
|
|
#include "user/ntuser/desktop.h"
|
|
#include "user/ntuser/dce.h"
|
|
#include "user/ntuser/focus.h"
|
|
#include "user/ntuser/hotkey.h"
|
|
#include "user/ntuser/input.h"
|
|
#include "user/ntuser/menu.h"
|
|
#include "user/ntuser/monitor.h"
|
|
#include "user/ntuser/timer.h"
|
|
#include "user/ntuser/caret.h"
|
|
#include "user/ntuser/painting.h"
|
|
#include "user/ntuser/class.h"
|
|
#include "user/ntuser/window.h"
|
|
#include "user/ntuser/security.h"
|
|
#include "user/ntuser/sysparams.h"
|
|
#include "user/ntuser/power.h"
|
|
#include "user/ntuser/prop.h"
|
|
#include "user/ntuser/guicheck.h"
|
|
#include "user/ntuser/useratom.h"
|
|
#include "user/ntuser/vis.h"
|
|
#include "user/ntuser/userfuncs.h"
|
|
#include "user/ntuser/scroll.h"
|
|
#include "user/ntuser/winpos.h"
|
|
#include "user/ntuser/callback.h"
|
|
#include "user/ntuser/mmcopy.h"
|
|
#include "user/ntuser/ghost.h"
|
|
|
|
/* CSRSS Interface */
|
|
#include "user/ntuser/csr.h"
|
|
|
|
#endif // __cplusplus
|
|
|
|
#include "gdi/ntgdi/gdidebug.h"
|