ReactOS 0.4.16-dev-334-g4d9f67c
logonui.c File Reference
#include "logonui.h"
Include dependency graph for logonui.c:

Go to the source code of this file.

Functions

static HDC DrawBaseBackground (HDC hdcDesktop)
 
static VOID DrawLogoffScreen (HDC hdcMem)
 
static BOOL ParseCmdline (int argc, WCHAR *argv[])
 
static VOID Run (VOID)
 
int WINAPI wWinMain (IN HINSTANCE hInst, IN HINSTANCE hPrevInstance, IN LPWSTR lpszCmdLine, IN int nCmdShow)
 

Variables

PINFO g_pInfo = NULL
 

Function Documentation

◆ DrawBaseBackground()

static HDC DrawBaseBackground ( HDC  hdcDesktop)
static

Definition at line 24 of file logonui.c.

25{
26 HDC hdcMem;
27
28 hdcMem = NT5_DrawBaseBackground(hdcDesktop);
29
30 return hdcMem;
31}
HDC NT5_DrawBaseBackground(HDC hdcDesktop)
Definition: NT5design.c:136
static HDC
Definition: imagelist.c:88
HDC hdcMem
Definition: welcome.c:104

Referenced by Run().

◆ DrawLogoffScreen()

static VOID DrawLogoffScreen ( HDC  hdcMem)
static

Definition at line 34 of file logonui.c.

35{
36 /* Draw the logoff icon */
37 NT5_CreateLogoffScreen(L"Saving your settings...", hdcMem);
38}
VOID NT5_CreateLogoffScreen(LPWSTR lpText, HDC hdcMem)
Definition: NT5design.c:125
#define L(x)
Definition: ntvdm.h:50

Referenced by Run().

◆ ParseCmdline()

static BOOL ParseCmdline ( int  argc,
WCHAR argv[] 
)
static

Definition at line 88 of file logonui.c.

89{
90 return TRUE;
91}
#define TRUE
Definition: types.h:120

Referenced by wWinMain().

◆ Run()

static VOID Run ( VOID  )
static

Definition at line 94 of file logonui.c.

95{
96 HWND hDesktopWnd;
97 HDC hdcDesktop, hdcMem;
98
99 /* Get the screen size */
102
103 hDesktopWnd = GetDesktopWindow();
104
105 /* Get the DC for the desktop */
106 hdcDesktop = GetDCEx(hDesktopWnd, NULL, DCX_CACHE);
107 if (hdcDesktop)
108 {
109 /* Initialize the base background onto a DC */
110 hdcMem = DrawBaseBackground(hdcDesktop);
111 if (hdcMem)
112 {
113 /* TEST : Draw logoff screen */
115
116 /* Blit the off-screen DC to the desktop */
117 BitBlt(hdcDesktop,
118 0,
119 0,
120 g_pInfo->cx,
121 g_pInfo->cy,
122 hdcMem,
123 0,
124 0,
125 SRCCOPY);
126
127 /* Delete the memory DC */
129 }
130
131 /* Release the desktop DC */
132 ReleaseDC(hDesktopWnd, hdcDesktop);
133 }
134}
#define NULL
Definition: types.h:112
static VOID BitBlt(_In_ ULONG Left, _In_ ULONG Top, _In_ ULONG Width, _In_ ULONG Height, _In_reads_bytes_(Delta *Height) PUCHAR Buffer, _In_ ULONG BitsPerPixel, _In_ ULONG Delta)
Definition: common.c:57
static HDC DrawBaseBackground(HDC hdcDesktop)
Definition: logonui.c:24
PINFO g_pInfo
Definition: logonui.c:17
static VOID DrawLogoffScreen(HDC hdcMem)
Definition: logonui.c:34
INT cx
Definition: logonui.h:9
INT cy
Definition: logonui.h:10
#define SRCCOPY
Definition: wingdi.h:333
BOOL WINAPI DeleteDC(_In_ HDC)
int WINAPI ReleaseDC(_In_opt_ HWND, _In_ HDC)
#define DCX_CACHE
Definition: winuser.h:2117
#define SM_CYSCREEN
Definition: winuser.h:963
HDC WINAPI GetDCEx(_In_opt_ HWND, _In_opt_ HRGN, _In_ DWORD)
HWND WINAPI GetDesktopWindow(void)
Definition: window.c:628
#define SM_CXSCREEN
Definition: winuser.h:962
int WINAPI GetSystemMetrics(_In_ int)

◆ wWinMain()

int WINAPI wWinMain ( IN HINSTANCE  hInst,
IN HINSTANCE  hPrevInstance,
IN LPWSTR  lpszCmdLine,
IN int  nCmdShow 
)

Definition at line 137 of file logonui.c.

141{
142 LPWSTR *lpArgs;
143 INT NumArgs;
144
145 /* Allocate memory for the data */
148 sizeof(INFO));
149 if (!g_pInfo) return -1;
150
152
153 /* Get the command line args */
154 lpArgs = CommandLineToArgvW(lpszCmdLine, &NumArgs);
155 if (lpArgs)
156 {
157 /* Parse the command line */
158 if (ParseCmdline(NumArgs, lpArgs))
159 {
160 /* Start the main routine */
161 Run();
162 }
163 }
164
165 /* Free the data */
167 0,
168 g_pInfo);
169
170 return 0;
171}
struct _INFO * PINFO
#define GetProcessHeap()
Definition: compat.h:736
#define HeapAlloc
Definition: compat.h:733
#define HeapFree(x, y, z)
Definition: compat.h:735
#define HEAP_ZERO_MEMORY
Definition: compat.h:134
#define INFO
Definition: debug.h:89
HINSTANCE hInst
Definition: dxdiag.c:13
static BOOL ParseCmdline(int argc, WCHAR *argv[])
Definition: logonui.c:88
LPWSTR *WINAPI CommandLineToArgvW(LPCWSTR lpCmdline, int *numargs)
Definition: shell32_main.c:79
HINSTANCE hInstance
Definition: logonui.h:8
int32_t INT
Definition: typedefs.h:58
struct tagRun Run
WCHAR * LPWSTR
Definition: xmlstorage.h:184

Variable Documentation

◆ g_pInfo

PINFO g_pInfo = NULL

Definition at line 17 of file logonui.c.

Referenced by Run(), and wWinMain().