[LOCALSPL]
[reactos.git] / reactos / win32ss / printing / providers / localspl / main.c
index 2e62069..458edba 100644 (file)
@@ -2,7 +2,7 @@
  * PROJECT:     ReactOS Local Spooler
  * LICENSE:     GNU LGPL v2.1 or any later version as published by the Free Software Foundation
  * PURPOSE:     Main functions
- * COPYRIGHT:   Copyright 2015 Colin Finck <colin@reactos.org>
+ * COPYRIGHT:   Copyright 2015-2017 Colin Finck <colin@reactos.org>
  */
 
 #include "precomp.h"
@@ -12,25 +12,14 @@ WCHAR wszSpoolDirectory[MAX_PATH];
 DWORD cchSpoolDirectory;
 
 // Global Constants
-const WCHAR wszCurrentEnvironment[] =
-#if defined(_X86_)
-    L"Windows NT x86";
-#elif defined(_AMD64_)
-    L"Windows x64";
-#elif defined(_ARM_)
-    L"Windows ARM";
-#else
-    #error Unsupported architecture
-#endif
-
-const DWORD cbCurrentEnvironment = sizeof(wszCurrentEnvironment);
+#include <prtprocenv.h>
 
 const WCHAR wszDefaultDocumentName[] = L"Local Downlevel Document";
 
 const WCHAR* wszPrintProviderInfo[3] = {
     L"Windows NT Local Print Providor",     // Name
-    L"Windows NT Local Printers",           // Description
-    L"Locally connected Printers"           // Comment
+    L"Locally connected Printers",          // Comment
+    L"Windows NT Local Printers"            // Description
 };
 
 // Local Constants
@@ -59,7 +48,7 @@ static const PRINTPROVIDOR _PrintProviderFunctions = {
     LocalWritePrinter,                          // fpWritePrinter
     LocalEndPagePrinter,                        // fpEndPagePrinter
     NULL,                                       // fpAbortPrinter
-    NULL,                                       // fpReadPrinter
+    LocalReadPrinter,                           // fpReadPrinter
     LocalEndDocPrinter,                         // fpEndDocPrinter
     LocalAddJob,                                // fpAddJob
     LocalScheduleJob,                           // fpScheduleJob
@@ -146,6 +135,7 @@ DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
             _GetSpoolDirectory();
 
             return InitializePrintMonitorList() &&
+                   InitializePortList() &&
                    InitializePrintProcessorList() &&
                    InitializePrinterList() &&
                    InitializeGlobalJobList();