--- /dev/null
+/*
+ * PROJECT: ReactOS system libraries
+ * LICENSE: GPL - See COPYING in the top level directory
+ * FILE: dll/win32/wlnotify/schedsvc.c
+ * PURPOSE: Scheduler service logon notifications
+ * PROGRAMMER: Eric Kohl <eric.kohl@reactos.org>
+ */
+
+#include "precomp.h"
+#include <winsvc.h>
+
+#define _NDEBUG
+#include <debug.h>
+
+
+VOID
+WINAPI
+SchedEventLogoff(
+ PWLX_NOTIFICATION_INFO pInfo)
+{
+ SC_HANDLE hManager = NULL;
+ SC_HANDLE hService = NULL;
+ SERVICE_STATUS ServiceStatus;
+
+ DPRINT("SchedStartShellEvent\n");
+ DPRINT("Size: %lu\n", pInfo->Size);
+ DPRINT("Flags: %lx\n", pInfo->Flags);
+ DPRINT("UserName: %S\n", pInfo->UserName);
+ DPRINT("Domain: %S\n", pInfo->Domain);
+ DPRINT("WindowStation: %S\n", pInfo->WindowStation);
+ DPRINT("hToken: %p\n", pInfo->hToken);
+ DPRINT("hDesktop: %p\n", pInfo->hDesktop);
+ DPRINT("pStatusCallback: %p\n", pInfo->pStatusCallback);
+
+ hManager = OpenSCManagerW(NULL, NULL, SC_MANAGER_CONNECT);
+ if (hManager == NULL)
+ {
+ DPRINT1("OpenSCManagerW() failed (Error %lu)\n", GetLastError());
+ goto done;
+ }
+
+ hService = OpenServiceW(hManager, L"Schedule", SERVICE_USER_DEFINED_CONTROL);
+ if (hManager == NULL)
+ {
+ DPRINT1("OpenServiceW() failed (Error %lu)\n", GetLastError());
+ goto done;
+ }
+
+ if (!ControlService(hService, 129, &ServiceStatus))
+ {
+ DPRINT1("ControlService() failed (Error %lu)\n", GetLastError());
+ }
+
+done:
+ if (hService != NULL)
+ CloseServiceHandle(hService);
+
+ if (hManager != NULL)
+ CloseServiceHandle(hManager);
+}
+
+
+VOID
+WINAPI
+SchedStartShell(
+ PWLX_NOTIFICATION_INFO pInfo)
+{
+ SC_HANDLE hManager = NULL;
+ SC_HANDLE hService = NULL;
+ SERVICE_STATUS ServiceStatus;
+
+ DPRINT("SchedStartShellEvent\n");
+ DPRINT("Size: %lu\n", pInfo->Size);
+ DPRINT("Flags: %lx\n", pInfo->Flags);
+ DPRINT("UserName: %S\n", pInfo->UserName);
+ DPRINT("Domain: %S\n", pInfo->Domain);
+ DPRINT("WindowStation: %S\n", pInfo->WindowStation);
+ DPRINT("hToken: %p\n", pInfo->hToken);
+ DPRINT("hDesktop: %p\n", pInfo->hDesktop);
+ DPRINT("pStatusCallback: %p\n", pInfo->pStatusCallback);
+
+ hManager = OpenSCManagerW(NULL, NULL, SC_MANAGER_CONNECT);
+ if (hManager == NULL)
+ {
+ DPRINT1("OpenSCManagerW() failed (Error %lu)\n", GetLastError());
+ goto done;
+ }
+
+ hService = OpenServiceW(hManager, L"Schedule", SERVICE_USER_DEFINED_CONTROL);
+ if (hManager == NULL)
+ {
+ DPRINT1("OpenServiceW() failed (Error %lu)\n", GetLastError());
+ goto done;
+ }
+
+ if (!ControlService(hService, 128, &ServiceStatus))
+ {
+ DPRINT1("ControlService() failed (Error %lu)\n", GetLastError());
+ }
+
+done:
+ if (hService != NULL)
+ CloseServiceHandle(hService);
+
+ if (hManager != NULL)
+ CloseServiceHandle(hManager);
+}
+
+/* EOF */
+;@ stub RegisterTicketExpiredNotificationEvent
+;@ stub SCardResumeCertProp
+;@ stub SCardStartCertProp
+;@ stub SCardStopCertProp
+;@ stub SCardSuspendCertProp
+@ stdcall SchedEventLogoff(ptr)
+@ stdcall SchedStartShell(ptr)
+;@ stub SensDisconnectEvent
+;@ stub SensLockEvent
+;@ stub SensLogoffEvent
+;@ stub SensLogonEvent
+;@ stub SensPostShellEvent
+;@ stub SensReconnectEvent
+;@ stub SensShutdownEvent
+;@ stub SensStartScreenSaverEvent
+;@ stub SensStartShellEvent
+;@ stub SensStartupEvent
+;@ stub SensStopScreenSaverEvent
+;@ stub SensUnlockEvent
+;@ stub ShowNotificationBallonW
@ stdcall TestDisconnectEvent(ptr)
@ stdcall TestLockEvent(ptr)
@ stdcall TestLogoffEvent(ptr)
@ stdcall TestStartupEvent(ptr)
@ stdcall TestStopScreenSaverEvent(ptr)
@ stdcall TestUnlockEvent(ptr)
+;@ stub TSEventDisconnect
+;@ stub TSEventLogoff
+;@ stub TSEventLogon
+;@ stub TSEventPostShell
+;@ stub TSEventReconnect
+;@ stub TSEventShutdown
+;@ stub TSEventStartShell
+;@ stub TSEventStartup
+;@ stub TermsrvCreateTempDir
+;@ stub UnregisterTicketExpiredNotificationEvent