summaryrefslogtreecommitdiff
path: root/src/fs/virtfstools.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/fs/virtfstools.cpp')
-rw-r--r--src/fs/virtfstools.cpp20
1 files changed, 11 insertions, 9 deletions
diff --git a/src/fs/virtfstools.cpp b/src/fs/virtfstools.cpp
index c9e976864..39f1ed413 100644
--- a/src/fs/virtfstools.cpp
+++ b/src/fs/virtfstools.cpp
@@ -224,34 +224,36 @@ namespace VirtFs
}
} // namespace VirtFs
+#ifdef USE_PHYSFS
// +++ temporary add it here
-namespace VirtFsDir
+namespace VirtFsPhys
{
void getFiles(const std::string &path,
StringVect &list)
{
- VirtList *const fonts = VirtFsDir::enumerateFiles(path);
+ VirtList *const fonts = VirtFsPhys::enumerateFiles(path);
FOR_EACH (StringVectCIter, i, fonts->names)
{
- if (!VirtFsDir::isDirectory(path + dirSeparator + *i))
+ if (!VirtFsPhys::isDirectory(path + dirSeparator + *i))
list.push_back(*i);
}
- VirtFsDir::freeList(fonts);
+ VirtFsPhys::freeList(fonts);
}
} // namespace VirtFs
-
+#else // USE_PHYSFS
// +++ temporary add it here
-namespace VirtFsPhys
+namespace VirtFsDir
{
void getFiles(const std::string &path,
StringVect &list)
{
- VirtList *const fonts = VirtFsPhys::enumerateFiles(path);
+ VirtList *const fonts = VirtFsDir::enumerateFiles(path);
FOR_EACH (StringVectCIter, i, fonts->names)
{
- if (!VirtFsPhys::isDirectory(path + dirSeparator + *i))
+ if (!VirtFsDir::isDirectory(path + dirSeparator + *i))
list.push_back(*i);
}
- VirtFsPhys::freeList(fonts);
+ VirtFsDir::freeList(fonts);
}
} // namespace VirtFs
+#endif // USE_PHYSFS