author | skyhusker <skyhusker> | 2005-03-06 19:31:56 (UTC) |
---|---|---|
committer | skyhusker <skyhusker> | 2005-03-06 19:31:56 (UTC) |
commit | 578cc81bc489015320351efd4fabcbed3355ac23 (patch) (unidiff) | |
tree | f40c155e58a993759b662e09b56051d8eb93cb49 | |
parent | a81251b503cba26ad326ac6c68a80a2930bef896 (diff) | |
download | opie-578cc81bc489015320351efd4fabcbed3355ac23.zip opie-578cc81bc489015320351efd4fabcbed3355ac23.tar.gz opie-578cc81bc489015320351efd4fabcbed3355ac23.tar.bz2 |
Fix bug 1600: Removing . from directory listing
-rw-r--r-- | noncore/graphics/opie-eye/impl/dir/dir_lister.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/noncore/graphics/opie-eye/impl/dir/dir_lister.cpp b/noncore/graphics/opie-eye/impl/dir/dir_lister.cpp index ff33cf2..5706598 100644 --- a/noncore/graphics/opie-eye/impl/dir/dir_lister.cpp +++ b/noncore/graphics/opie-eye/impl/dir/dir_lister.cpp | |||
@@ -39,25 +39,28 @@ QString Dir_DirLister::setStartPath( const QString& path ) { | |||
39 | m_currentDir.cd(defaultPath()); | 39 | m_currentDir.cd(defaultPath()); |
40 | 40 | ||
41 | 41 | ||
42 | return m_currentDir.absPath(); | 42 | return m_currentDir.absPath(); |
43 | } | 43 | } |
44 | 44 | ||
45 | QString Dir_DirLister::currentPath()const { | 45 | QString Dir_DirLister::currentPath()const { |
46 | return m_currentDir.absPath(); | 46 | return m_currentDir.absPath(); |
47 | } | 47 | } |
48 | 48 | ||
49 | 49 | ||
50 | QStringList Dir_DirLister::folders()const { | 50 | QStringList Dir_DirLister::folders()const { |
51 | return m_currentDir.entryList( QDir::Dirs ); | 51 | QStringList dirs = m_currentDir.entryList( QDir::Dirs ); |
52 | dirs.remove("."); | ||
53 | |||
54 | return dirs; | ||
52 | } | 55 | } |
53 | 56 | ||
54 | QStringList Dir_DirLister::recFiles(const QString&aPath,int currentDepth)const | 57 | QStringList Dir_DirLister::recFiles(const QString&aPath,int currentDepth)const |
55 | { | 58 | { |
56 | QStringList all; | 59 | QStringList all; |
57 | if (currentDepth>m_recDepth) return all; | 60 | if (currentDepth>m_recDepth) return all; |
58 | 61 | ||
59 | QString subPath; | 62 | QString subPath; |
60 | subPath = aPath; | 63 | subPath = aPath; |
61 | if (subPath.length()==0) { | 64 | if (subPath.length()==0) { |
62 | subPath="."; | 65 | subPath="."; |
63 | } | 66 | } |