| 194 | namespace |
| 195 | { |
| 196 | int CompareDirectoryListing(const String& text, const String& other) |
| 197 | { |
| 198 | if (text == other) |
| 199 | return 0; |
| 200 | bool isDir = text == ".." || File(text).isDirectory(); |
| 201 | bool isOtherDir = other == ".." || File(other).isDirectory(); |
| 202 | if (isDir && !isOtherDir) |
| 203 | return -1; |
| 204 | if (!isDir && isOtherDir) |
| 205 | return 1; |
| 206 | return text.compareIgnoreCase(other); |
| 207 | } |
| 208 | |
| 209 | void SortDirectoryListing(StringArray& listing) |
| 210 | { |
no outgoing calls
no test coverage detected