#ifndef FILE_BROWSE_HPP #define FILE_BROWSE_HPP #include #include #include #include using namespace std; struct DirEntry { std::string name; std::string path; bool isDirectory; off_t size; }; bool nameEndsWith(const std::string& name, const std::vector extensionList); void getDirectoryContents(std::vector& dirContents, const std::vector extensionList); void getDirectoryContents(std::vector& dirContents); std::vector getContents(const std::string &name, const std::vector &extensionList); bool returnIfExist(const std::string &path, const std::vector &extensionList); std::string selectFilePath(std::string selectText, std::string initialPath, const std::vector &extensionList, int selectionMode = 1); void dirCopy(DirEntry* entry, int i, const char *destinationPath, const char *sourcePath); int fcopy(const char *sourcePath, const char *destinationPath); #endif //FILE_BROWSE_HPP