Changeset 7625 in orxonox.OLD for branches/qt_gui/src/lib/util/directory.cc
- Timestamp:
- May 16, 2006, 9:17:10 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/qt_gui/src/lib/util/directory.cc
r7624 r7625 42 42 #endif 43 43 Directory::Directory(const std::string& directoryName) 44 :willfail(false)44 : File(directoryName), willfail(false) 45 45 { 46 46 this->handle = 0; … … 52 52 } 53 53 54 bool Directory::open( const std::string& directoryName)54 bool Directory::open() 55 55 { 56 56 #if not defined(__WIN32__) 57 57 if (this->handle != NULL) 58 58 this->close(); 59 this->handle = opendir( directoryName.c_str());59 this->handle = opendir(this->name().c_str()); 60 60 if (!handle) 61 61 willfail = true; … … 75 75 // First check the attributes trying to access a non-Directory with 76 76 // FindFirstFile takes ages 77 DWORD attrs = GetFileAttributes( directoryName.c_str());77 DWORD attrs = GetFileAttributes(this->name().c_str()); 78 78 if ( (attrs == 0xFFFFFFFF) || ((attrs && FILE_ATTRIBUTE_DIRECTORY) == 0) ) 79 79 { … … 81 81 return false; 82 82 } 83 std::string Full( directoryName);83 std::string Full(this->name()); 84 84 // Circumvent a problem in FindFirstFile with c:\\* as parameter 85 85 if ( (Full.length() > 0) && (Full[Full.length()-1] != '\\') )
Note: See TracChangeset
for help on using the changeset viewer.