]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/filename.cpp
remove run-time check for now-required GTK 2.4
[wxWidgets.git] / src / common / filename.cpp
index 0cacb63e47029db9e9f242774008b36776b951aa..79e2cae278bf61ba61ed050a2e7f39b3385223bc 100644 (file)
@@ -640,8 +640,8 @@ bool wxFileSystemObjectExists(const wxString& path, int flags)
 {
     // Should the existence of file/directory with this name be accepted, i.e.
     // result in the true return value from this function?
-    const bool acceptFile = flags & wxFileSystemObject_File;
-    const bool acceptDir  = flags & wxFileSystemObject_Dir;
+    const bool acceptFile = (flags & wxFileSystemObject_File) != 0;
+    const bool acceptDir  = (flags & wxFileSystemObject_Dir) != 0;
 
     wxString strPath(path);
 
@@ -2666,12 +2666,14 @@ bool wxFileName::GetTimes(wxDateTime *dtAccess,
     wxStructStat stBuf;
     if ( wxStat( GetFullPath(), &stBuf) == 0 )
     {
+        // Android defines st_*time fields as unsigned long, but time_t as long,
+        // hence the static_casts.
         if ( dtAccess )
-            dtAccess->Set(stBuf.st_atime);
+            dtAccess->Set(static_cast<time_t>(stBuf.st_atime));
         if ( dtMod )
-            dtMod->Set(stBuf.st_mtime);
+            dtMod->Set(static_cast<time_t>(stBuf.st_mtime));
         if ( dtCreate )
-            dtCreate->Set(stBuf.st_ctime);
+            dtCreate->Set(static_cast<time_t>(stBuf.st_ctime));
 
         return true;
     }