- Sync with trunk r58248 to bring the latest changes from Amine (headers) and others...
[reactos.git] / dll / cpl / desk / desk.h
1 #define COBJMACROS
2
3 #define WIN32_NO_STATUS
4 #define _INC_WINDOWS
5 #define COM_NO_WINDOWS_H
6 #include <stdarg.h>
7 #include <windef.h>
8 #include <winbase.h>
9 #include <winreg.h>
10 #include <wingdi.h>
11 #include <winuser.h>
12 #include <shellapi.h>
13 #include <commdlg.h>
14 #include <cpl.h>
15 #include <tchar.h>
16 #include <setupapi.h>
17 #include <shlobj.h>
18 #include <regstr.h>
19 #include <cplext.h>
20 #include <dll/desk/deskcplx.h>
21 #include <cfgmgr32.h>
22 #include <uxtheme.h>
23 #include <uxundoc.h>
24
25 #include "appearance.h"
26 #include "preview.h"
27 #include "draw.h"
28 #include "monslctl.h"
29
30 #include "resource.h"
31
32 typedef struct _APPLET
33 {
34 int idIcon;
35 int idName;
36 int idDescription;
37 APPLET_PROC AppletProc;
38 } APPLET, *PAPPLET;
39
40 typedef struct _DIBITMAP
41 {
42 BITMAPFILEHEADER *header;
43 BITMAPINFO *info;
44 BYTE *bits;
45 int width;
46 int height;
47 } DIBITMAP, *PDIBITMAP;
48
49 extern HINSTANCE hApplet;
50
51 HMENU
52 LoadPopupMenu(IN HINSTANCE hInstance,
53 IN LPCTSTR lpMenuName);
54
55 PDIBITMAP DibLoadImage(LPTSTR lpFilename);
56 VOID DibFreeImage(PDIBITMAP lpBitmap);
57
58 INT AllocAndLoadString(LPTSTR *lpTarget,
59 HINSTANCE hInst,
60 UINT uID);
61
62 ULONG __cdecl DbgPrint(PCCH Format,...);
63
64 #define MAX_DESK_PAGES 32
65 #define NUM_SPECTRUM_BITMAPS 3
66
67 /* As slider control can't contain user data, we have to keep an
68 * array of RESOLUTION_INFO to have our own associated data.
69 */
70 typedef struct _RESOLUTION_INFO
71 {
72 DWORD dmPelsWidth;
73 DWORD dmPelsHeight;
74 } RESOLUTION_INFO, *PRESOLUTION_INFO;
75
76 typedef struct _SETTINGS_ENTRY
77 {
78 struct _SETTINGS_ENTRY *Blink;
79 struct _SETTINGS_ENTRY *Flink;
80 DWORD dmBitsPerPel;
81 DWORD dmPelsWidth;
82 DWORD dmPelsHeight;
83 DWORD dmDisplayFrequency;
84 } SETTINGS_ENTRY, *PSETTINGS_ENTRY;
85
86 typedef struct _DISPLAY_DEVICE_ENTRY
87 {
88 struct _DISPLAY_DEVICE_ENTRY *Flink;
89 LPTSTR DeviceDescription;
90 LPTSTR DeviceName;
91 LPTSTR DeviceKey;
92 LPTSTR DeviceID;
93 DWORD DeviceStateFlags;
94 PSETTINGS_ENTRY Settings; /* Sorted by increasing dmPelsHeight, BPP */
95 DWORD SettingsCount;
96 PRESOLUTION_INFO Resolutions;
97 DWORD ResolutionsCount;
98 PSETTINGS_ENTRY CurrentSettings; /* Points into Settings list */
99 SETTINGS_ENTRY InitialSettings;
100 } DISPLAY_DEVICE_ENTRY, *PDISPLAY_DEVICE_ENTRY;
101
102 typedef struct _GLOBAL_DATA
103 {
104 COLORREF desktop_color;
105 } GLOBAL_DATA, *PGLOBAL_DATA;
106
107 extern GLOBAL_DATA g_GlobalData;
108
109 BOOL
110 DisplayAdvancedSettings(HWND hWndParent, PDISPLAY_DEVICE_ENTRY DisplayDevice);
111
112 IDataObject *
113 CreateDevSettings(PDISPLAY_DEVICE_ENTRY DisplayDeviceInfo);
114
115 HPSXA WINAPI SHCreatePropSheetExtArrayEx(HKEY,LPCWSTR,UINT,IDataObject*);
116
117 INT_PTR CALLBACK
118 AdvGeneralPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);