aboutsummaryrefslogtreecommitdiff
path: root/common/archive.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'common/archive.cpp')
-rw-r--r--common/archive.cpp15
1 files changed, 5 insertions, 10 deletions
diff --git a/common/archive.cpp b/common/archive.cpp
index d494c6ceb4..85586c2820 100644
--- a/common/archive.cpp
+++ b/common/archive.cpp
@@ -76,14 +76,11 @@ public:
FSDirectoryMember(FSNode &node) : _node(node) {
}
- /*
- NOTE/FIXME: since I assume that the only use case for getName()
- is for error messages, I am returning the full path of the node
- here. This seems better than we did before, when matchPattern
- and getAllNames used to work with StringList, and we used to
- put the relative path of the file to the list instead.
- */
String getName() const {
+ return _node.getName();
+ }
+
+ String getDisplayName() const {
return _node.getPath();
}
@@ -92,8 +89,6 @@ public:
}
};
-typedef SharedPtr<FSDirectoryMember> FSDirectoryMemberPtr;
-
FSDirectory::FSDirectory(const FSNode &node, int depth)
: _node(node), _cached(false), _depth(depth) {
}
@@ -259,7 +254,7 @@ int FSDirectory::listMatchingMembers(ArchiveMemberList &list, const String &patt
NodeCache::iterator it = _fileCache.begin();
for ( ; it != _fileCache.end(); it++) {
if ((*it)._key.matchString(lowercasePattern)) {
- list.push_back(FSDirectoryMemberPtr(new FSDirectoryMember((*it)._value)));
+ list.push_back(ArchiveMemberPtr(new FSDirectoryMember((*it)._value)));
matches++;
}
}