setupapi: Implement SetupGetFileCompressionInfo on top of SetupGetFileCompressionInfoEx.
[wine] / dlls / localui / localui.c
1 /*
2  * Implementation of the Local Printmonitor User Interface
3  *
4  * Copyright 2007 Detlef Riekenberg
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19  */
20
21 #include <stdarg.h>
22
23 #define NONAMELESSUNION
24
25 #include "windef.h"
26 #include "winbase.h"
27 #include "wingdi.h"
28 #include "winreg.h"
29
30 #include "winspool.h"
31 #include "ddk/winsplp.h"
32
33 #include "wine/debug.h"
34
35 WINE_DEFAULT_DEBUG_CHANNEL(localui);
36
37 static HINSTANCE LOCALUI_hInstance;
38
39 /*****************************************************
40  *   localui_AddPortUI [exported through MONITORUI]
41  *
42  * Display a Dialog to add a local Port
43  *
44  * PARAMS
45  *  pName       [I] Servername or NULL (local Computer)
46  *  hWnd        [I] Handle to parent Window for the Dialog-Box or NULL
47  *  pMonitorName[I] Name of the Monitor, that should be used to add a Port or NULL
48  *  ppPortName  [O] PTR to PTR of a buffer, that receive the Name of the new Port or NULL
49  *
50  * RETURNS
51  *  Success: TRUE
52  *  Failure: FALSE
53  *
54  */
55 static BOOL WINAPI localui_AddPortUI(PCWSTR pName, HWND hWnd, PCWSTR pMonitorName, PWSTR *ppPortName)
56 {
57     FIXME("(%s, %p, %s, %p) stub\n", debugstr_w(pName), hWnd, debugstr_w(pMonitorName), ppPortName);
58     return TRUE;
59 }
60
61
62 /*****************************************************
63  *   localui_ConfigurePortUI [exported through MONITORUI]
64  *
65  * Display the Configuration-Dialog for a specific Port
66  *
67  * PARAMS
68  *  pName     [I] Servername or NULL (local Computer)
69  *  hWnd      [I] Handle to parent Window for the Dialog-Box or NULL
70  *  pPortName [I] Name of the Port, that should be configured
71  *
72  * RETURNS
73  *  Success: TRUE
74  *  Failure: FALSE
75  *
76  */
77 static BOOL WINAPI localui_ConfigurePortUI(PCWSTR pName, HWND hWnd, PCWSTR pPortName)
78 {
79     FIXME("(%s, %p, %s) stub\n", debugstr_w(pName), hWnd, debugstr_w(pPortName));
80     return TRUE;
81 }
82
83 /*****************************************************
84  *   localui_DeletePortUI [exported through MONITORUI]
85  *
86  * Delete a specific Port
87  *
88  * PARAMS
89  *  pName     [I] Servername or NULL (local Computer)
90  *  hWnd      [I] Handle to parent Window
91  *  pPortName [I] Name of the Port, that should be deleted
92  *
93  * RETURNS
94  *  Success: TRUE
95  *  Failure: FALSE
96  *
97  */
98 static BOOL WINAPI localui_DeletePortUI(PCWSTR pName, HWND hWnd, PCWSTR pPortName)
99 {
100     FIXME("(%s, %p, %s) stub\n", debugstr_w(pName), hWnd, debugstr_w(pPortName));
101     return TRUE;
102 }
103
104 /*****************************************************
105  *      InitializePrintMonitorUI  (LOCALUI.@)
106  *
107  * Initialize the User-Interface for the Local Ports
108  *
109  * RETURNS
110  *  Success: Pointer to a MONITORUI Structure
111  *  Failure: NULL
112  *
113  */
114
115 PMONITORUI WINAPI InitializePrintMonitorUI(void)
116 {
117     static MONITORUI mymonitorui =
118     {
119         sizeof(MONITORUI),
120         localui_AddPortUI,
121         localui_ConfigurePortUI,
122         localui_DeletePortUI
123     };
124
125     TRACE("=> %p\n", &mymonitorui);
126     return &mymonitorui;
127 }
128
129 /*****************************************************
130  *      DllMain
131  */
132 BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
133 {
134     TRACE("(%p, %d, %p)\n",hinstDLL, fdwReason, lpvReserved);
135
136     switch(fdwReason)
137     {
138         case DLL_WINE_PREATTACH:
139             return FALSE;           /* prefer native version */
140
141         case DLL_PROCESS_ATTACH:
142             DisableThreadLibraryCalls( hinstDLL );
143             LOCALUI_hInstance = hinstDLL;
144             break;
145     }
146     return TRUE;
147 }