summaryrefslogtreecommitdiff
path: root/plugingui/directory.cc
diff options
context:
space:
mode:
Diffstat (limited to 'plugingui/directory.cc')
-rw-r--r--plugingui/directory.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/plugingui/directory.cc b/plugingui/directory.cc
index b9188b8..17190e7 100644
--- a/plugingui/directory.cc
+++ b/plugingui/directory.cc
@@ -125,8 +125,10 @@ Directory::EntryList Directory::listFiles(std::string path) {
std::string name = entry->d_name;
if(name == ".") continue;
+#ifndef WIN32
if(Directory::isRoot(path) && name == "..") continue;
-
+#endif
+
entries.push_back(entry->d_name);
}
@@ -134,7 +136,8 @@ Directory::EntryList Directory::listFiles(std::string path) {
}
bool Directory::isRoot(std::string path) {
-#ifdef WIN32
+#ifdef WIN32
+ std::transform(data.begin(), data.end(), data.begin(), ::tolower);
// TODO: This is not a correct root calculation, but works with partitions
if(path.size() == 2) {
if(path == root()) return true;