Mercurial > projects > dynamin
comparison dynamin/c/windows.d @ 20:63cbfb167240
Got the COM code working in DirectoryDialog, but
it doesn't do what I thought it would. Instead of just preselecting the directory, it shows only it and its subfolders.
author | Jordan Miner <jminer7@gmail.com> |
---|---|
date | Fri, 24 Jul 2009 15:11:22 -0500 |
parents | e6e201c3a439 |
children | d0ce1db78819 |
comparison
equal
deleted
inserted
replaced
19:e4dabffaa784 | 20:63cbfb167240 |
---|---|
1376 | 1376 |
1377 BOOL SHGetPathFromIDListW(ITEMIDLIST* pidl, LPWSTR pszPath); | 1377 BOOL SHGetPathFromIDListW(ITEMIDLIST* pidl, LPWSTR pszPath); |
1378 | 1378 |
1379 HRESULT SHGetFolderPathW(HWND hwnd, int csidl, HANDLE hToken, DWORD dwFlags, LPWSTR pszPath); | 1379 HRESULT SHGetFolderPathW(HWND hwnd, int csidl, HANDLE hToken, DWORD dwFlags, LPWSTR pszPath); |
1380 | 1380 |
1381 HRESULT SHGetDesktopFolder(IShellFolder** ppshf); | 1381 HRESULT SHGetDesktopFolder(IShellFolder* ppshf); |
1382 | 1382 |
1383 struct GUID { | 1383 struct GUID { |
1384 align(1): | 1384 align(1): |
1385 uint Data1; | 1385 uint Data1; |
1386 ushort Data2; | 1386 ushort Data2; |
1388 ubyte[8] Data4; | 1388 ubyte[8] Data4; |
1389 } | 1389 } |
1390 alias GUID IID; | 1390 alias GUID IID; |
1391 alias GUID CLSID; | 1391 alias GUID CLSID; |
1392 | 1392 |
1393 // I can't get this #!@#! COM stuff working... | |
1394 interface IUnknown { | 1393 interface IUnknown { |
1395 extern(Windows): | |
1396 HRESULT QueryInterface(IID* riid, void** ppvObject); | 1394 HRESULT QueryInterface(IID* riid, void** ppvObject); |
1397 ULONG AddRef(); | 1395 ULONG AddRef(); |
1398 ULONG Release(); | 1396 ULONG Release(); |
1399 } | 1397 } |
1400 alias void* LPBC; | 1398 alias void IBindCtx; |
1401 interface IShellFolder : IUnknown { | 1399 interface IShellFolder : IUnknown { |
1402 extern(Windows): | |
1403 HRESULT ParseDisplayName( | 1400 HRESULT ParseDisplayName( |
1404 HWND hwnd, | 1401 HWND hwnd, |
1405 LPBC pbc, | 1402 IBindCtx* pbc, |
1406 wchar* pszDisplayName, | 1403 wchar* pszDisplayName, |
1407 ULONG* pchEaten, | 1404 ULONG* pchEaten, |
1408 ITEMIDLIST** ppidl, | 1405 ITEMIDLIST** ppidl, |
1409 ULONG* pdwAttributes); | 1406 ULONG* pdwAttributes); |
1410 | 1407 |