Logo Search packages:      
Sourcecode: scummvm version File versions

bool File::exists ( const String filename  )  [static]

Checks if a given file exists in any of the current default paths (those were/are added by addDefaultDirectory and/or addDefaultDirectoryRecursive).

filename the file to check for
true if the file exists, false otherwise

Definition at line 105 of file file.cpp.

      if (SearchMan.hasFile(filename)) {
            return true;
      } else if (SearchMan.hasFile(filename + ".")) {
            // WORKAROUND: Bug #1458388: "SIMON1: Game Detection fails"
            // sometimes instead of "GAMEPC" we get "GAMEPC." (note trailing dot)
            return true;

      return false;

Generated by  Doxygen 1.6.0   Back to index