annotate win32/lmremutl.d @ 1:4a9dcbd9e54f

-files of 0.13 beta -fixes so that it now compiles with the current dmd version
author marton@basel.hu
date Tue, 05 Apr 2011 20:44:01 +0200
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
1 /***********************************************************************\
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
2 * lmremutl.d *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
3 * *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
4 * Windows API header module *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
5 * *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
6 * Translated from MinGW Windows headers *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
7 * *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
8 * Placed into public domain *
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
9 \***********************************************************************/
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
10 module win32.lmremutl;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
11 pragma(lib, "netapi32.lib");
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
12
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
13 // D Conversion Note: DESC_CHAR is defined as TCHAR.
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
14
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
15 private import win32.lmcons, win32.windef;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
16
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
17 const SUPPORTS_REMOTE_ADMIN_PROTOCOL = 2;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
18 const SUPPORTS_RPC = 4;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
19 const SUPPORTS_SAM_PROTOCOL = 8;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
20 const SUPPORTS_UNICODE = 16;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
21 const SUPPORTS_LOCAL = 32;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
22 const SUPPORTS_ANY = 0xFFFFFFFF;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
23
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
24 const NO_PERMISSION_REQUIRED = 1;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
25 const ALLOCATE_RESPONSE = 2;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
26 const USE_SPECIFIC_TRANSPORT = 0x80000000;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
27
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
28 //[Yes] #ifndef DESC_CHAR_UNICODE
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
29 //alias CHAR DESC_CHAR;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
30 //} else {
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
31 //[No] #else
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
32 //[No] typedef WCHAR DESC_CHAR;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
33 //[No] #endif
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
34 // FIXME (D): Is this OK?
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
35 alias TCHAR DESC_CHAR;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
36
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
37 alias DESC_CHAR* LPDESC;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
38
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
39 struct TIME_OF_DAY_INFO {
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
40 DWORD tod_elapsedt;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
41 DWORD tod_msecs;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
42 DWORD tod_hours;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
43 DWORD tod_mins;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
44 DWORD tod_secs;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
45 DWORD tod_hunds;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
46 LONG tod_timezone;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
47 DWORD tod_tinterval;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
48 DWORD tod_day;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
49 DWORD tod_month;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
50 DWORD tod_year;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
51 DWORD tod_weekday;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
52 }
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
53 alias TIME_OF_DAY_INFO* PTIME_OF_DAY_INFO, LPTIME_OF_DAY_INFO;
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
54
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
55 extern (Windows) {
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
56 NET_API_STATUS NetRemoteTOD(LPCWSTR, PBYTE*);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
57 NET_API_STATUS NetRemoteComputerSupports(LPCWSTR, DWORD, PDWORD);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
58 NET_API_STATUS RxRemoteApi(DWORD, LPCWSTR, LPDESC, LPDESC, LPDESC,
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
59 LPDESC, LPDESC, LPDESC, LPDESC, DWORD, ...);
4a9dcbd9e54f -files of 0.13 beta
marton@basel.hu
parents:
diff changeset
60 }