comparison dynamin/gui/windows_directory_dialog.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 836a064828e8
children d0ce1db78819
comparison
equal deleted inserted replaced
19:e4dabffaa784 20:63cbfb167240
33 //bi.hwndOwner = ; 33 //bi.hwndOwner = ;
34 bi.lpszTitle = "Choose a folder:"; 34 bi.lpszTitle = "Choose a folder:";
35 bi.ulFlags |= BIF_RETURNONLYFSDIRS; 35 bi.ulFlags |= BIF_RETURNONLYFSDIRS;
36 bi.ulFlags |= BIF_USENEWUI; 36 bi.ulFlags |= BIF_USENEWUI;
37 37
38 // TODO: I can't get this #!@#! COM stuff working... 38 //IShellFolder shf;
39 //IShellFolder* shf;
40 //SHGetDesktopFolder(&shf); 39 //SHGetDesktopFolder(&shf);
41 //ITEMIDLIST* pidlInit; 40 //ITEMIDLIST* pidlInit;
42 //shf.ParseDisplayName(null, null, toWcharPointer(directory), null, &pidlInit, null); 41 //shf.ParseDisplayName(null, null, toWcharPtr(directory), null, &pidlInit, null);
43 //shf.Release(); 42 //shf.Release();
44 //bi.pidlRoot = pidlInit; 43 //bi.pidlRoot = pidlInit;
45 44
46 ITEMIDLIST* pidl = SHBrowseForFolder(&bi); 45 ITEMIDLIST* pidl = SHBrowseForFolder(&bi);
47 //CoTaskMemFree(pidlInit); 46 //CoTaskMemFree(pidlInit);