Remove use of GetVolumeInformation since it causes long delays on network drives.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39843 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
800991b674
commit
58f1fdc926
@ -121,14 +121,8 @@ size_t wxGetAvailableDrives(wxArrayString &paths, wxArrayString &names, wxArrayI
|
|||||||
path.Printf(wxT("%c:\\"), driveBuffer[i]);
|
path.Printf(wxT("%c:\\"), driveBuffer[i]);
|
||||||
name.Printf(wxT("%c:"), driveBuffer[i]);
|
name.Printf(wxT("%c:"), driveBuffer[i]);
|
||||||
|
|
||||||
#if !defined(__WXWINCE__)
|
// Do not use GetVolumeInformation to further decorate the
|
||||||
wxChar pname[52]; // FIXME: why 52 and not MAX_PATH or whatever?
|
// name, since it can cause severe delays on network drives.
|
||||||
if ( GetVolumeInformation(path, pname, WXSIZEOF(pname),
|
|
||||||
NULL, NULL, NULL, NULL, 0) )
|
|
||||||
{
|
|
||||||
name << _T(' ') << pname;
|
|
||||||
}
|
|
||||||
#endif // __WXWINCE__
|
|
||||||
|
|
||||||
int imageId;
|
int imageId;
|
||||||
int driveType = ::GetDriveType(path);
|
int driveType = ::GetDriveType(path);
|
||||||
|
Loading…
Reference in New Issue
Block a user