diff --git a/Standard Gaming Platform/CMakeLists.txt b/Standard Gaming Platform/CMakeLists.txt index f56cf667b..c39224f53 100644 --- a/Standard Gaming Platform/CMakeLists.txt +++ b/Standard Gaming Platform/CMakeLists.txt @@ -24,7 +24,6 @@ set(SGPSrc "${CMAKE_CURRENT_SOURCE_DIR}/PCX.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/PngLoader.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/Random.cpp" -"${CMAKE_CURRENT_SOURCE_DIR}/readdir.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/RegInst.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/sgp.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/sgp_logger.cpp" diff --git a/Standard Gaming Platform/readdir.cpp b/Standard Gaming Platform/readdir.cpp deleted file mode 100644 index 57a8c8523..000000000 --- a/Standard Gaming Platform/readdir.cpp +++ /dev/null @@ -1,22 +0,0 @@ -// -// Snap: Implementation of the TReadDir class -// This class reads the contents of a directory file-by-file -// -#include "readdir.h" - -TReadDir::TReadDir(char const* searchPattern) -{ - fSearchHandle = FindFirstFile(searchPattern, &fFileInfo); - fFirstRequest = true; -} - - -bool TReadDir::NextFile(char const* &fileName, unsigned &attrib) -{ - if (fSearchHandle == INVALID_HANDLE_VALUE) return false; - if (fFirstRequest) fFirstRequest = false; - else if ( !FindNextFile(fSearchHandle, &fFileInfo) ) return false; - fileName = fFileInfo.cFileName; - attrib = fFileInfo.dwFileAttributes; - return true; -} diff --git a/Standard Gaming Platform/readdir.h b/Standard Gaming Platform/readdir.h deleted file mode 100644 index b98ebae1e..000000000 --- a/Standard Gaming Platform/readdir.h +++ /dev/null @@ -1,27 +0,0 @@ -// -// Snap: Declaration of the TReadDir class -// This class reads the contents of a directory file-by-file -// -#ifndef READDIR_H -#define READDIR_H - -#include - -class TReadDir { -public: - - TReadDir(char const* searchPattern); - - ~TReadDir() { FindClose(fSearchHandle); } - - bool NextFile(char const* &fileName, unsigned &attrib); - -private: - - HANDLE fSearchHandle; - WIN32_FIND_DATA fFileInfo; - bool fFirstRequest; -}; - - -#endif // #ifndef READDIR_H \ No newline at end of file