]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/filename.cpp
correct GetBestSize() to return correct best size, i.e. the same size as AutoSize...
[wxWidgets.git] / src / common / filename.cpp
index cd32280ec627343faddc355a7055fce62820ce6e..234ac801380c964f309a0d55bb62e051da451650 100644 (file)
@@ -1793,7 +1793,7 @@ wxString wxFileName::GetLongPath() const
     wxString pathOut,
              path = GetFullPath();
 
-#if defined(__WIN32__) && !defined(__WXMICROWIN__)
+#if defined(__WIN32__) && !defined(__WXWINCE__) && !defined(__WXMICROWIN__)
 
 #if wxUSE_DYNAMIC_LOADER
     typedef DWORD (WINAPI *GET_LONG_PATH_NAME)(const wxChar *, wxChar *, DWORD);
@@ -2216,7 +2216,7 @@ bool wxFileName::GetTimes(wxDateTime *dtAccess,
     // not 9x
     bool ok;
     FILETIME ftAccess, ftCreate, ftWrite;
-    if ( DirExists() ) // Don't use IsDir, because it returns false even if it's a directory
+    if ( IsDir() ) 
     {
         // implemented in msw/dir.cpp
         extern bool wxGetDirectoryTimes(const wxString& dirname,
@@ -2255,6 +2255,7 @@ bool wxFileName::GetTimes(wxDateTime *dtAccess,
         return true;
     }
 #elif defined(__UNIX_LIKE__) || defined(__WXMAC__) || defined(__OS2__) || (defined(__DOS__) && defined(__WATCOMC__))
+    // no need to test for IsDir() here
     wxStructStat stBuf;
     if ( wxStat( GetFullPath().c_str(), &stBuf) == 0 )
     {