author | bipolar <bipolar> | 2002-03-02 00:36:54 (UTC) |
---|---|---|
committer | bipolar <bipolar> | 2002-03-02 00:36:54 (UTC) |
commit | 1b89006f83e7516e13f808742d118e209377abcc (patch) (unidiff) | |
tree | 853cb0772bcf385eb5e342f20ffbbdbb91a3c4a4 /core/apps/textedit/fileBrowser.cpp | |
parent | d81f7934384adf5c06dddc1998e01d474419c7b0 (diff) | |
download | opie-1b89006f83e7516e13f808742d118e209377abcc.zip opie-1b89006f83e7516e13f808742d118e209377abcc.tar.gz opie-1b89006f83e7516e13f808742d118e209377abcc.tar.bz2 |
ljp (llornkcor) commit: fixed file dialogs not showing hidden files and dirs.
Diffstat (limited to 'core/apps/textedit/fileBrowser.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/apps/textedit/fileBrowser.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/core/apps/textedit/fileBrowser.cpp b/core/apps/textedit/fileBrowser.cpp index 3e3cc3a..b029e5b 100644 --- a/core/apps/textedit/fileBrowser.cpp +++ b/core/apps/textedit/fileBrowser.cpp | |||
@@ -68,20 +68,20 @@ fileBrowser::~fileBrowser() | |||
68 | 68 | ||
69 | 69 | ||
70 | void fileBrowser::populateList() | 70 | void fileBrowser::populateList() |
71 | { | 71 | { |
72 | ListView->clear(); | 72 | ListView->clear(); |
73 | //qDebug(currentDir.canonicalPath()); | 73 | //qDebug(currentDir.canonicalPath()); |
74 | currentDir.setFilter( QDir::Files | QDir::Dirs | QDir::Hidden ); | 74 | currentDir.setFilter( QDir::Files | QDir::Dirs | QDir::Hidden | QDir::All); |
75 | currentDir.setSorting(/* QDir::Size*/ /*| QDir::Reversed | */QDir::DirsFirst); | 75 | currentDir.setSorting(/* QDir::Size*/ /*| QDir::Reversed | */QDir::DirsFirst); |
76 | currentDir.setMatchAllDirs(TRUE); | 76 | currentDir.setMatchAllDirs(TRUE); |
77 | 77 | ||
78 | currentDir.setNameFilter(filterStr); | 78 | currentDir.setNameFilter(filterStr); |
79 | // currentDir.setNameFilter("*.txt;*.etx"); | 79 | // currentDir.setNameFilter("*.txt;*.etx"); |
80 | QString fileL, fileS; | 80 | QString fileL, fileS; |
81 | const QFileInfoList *list = currentDir.entryInfoList(QDir::All /*, QDir::SortByMask*/); | 81 | const QFileInfoList *list = currentDir.entryInfoList( /*QDir::All*/ /*, QDir::SortByMask*/); |
82 | QFileInfoListIterator it(*list); | 82 | QFileInfoListIterator it(*list); |
83 | QFileInfo *fi; | 83 | QFileInfo *fi; |
84 | while ( (fi=it.current()) ) { | 84 | while ( (fi=it.current()) ) { |
85 | 85 | ||
86 | if (fi->isSymLink() ){ | 86 | if (fi->isSymLink() ){ |
87 | QString symLink=fi->readLink(); | 87 | QString symLink=fi->readLink(); |
@@ -93,13 +93,13 @@ void fileBrowser::populateList() | |||
93 | } else { | 93 | } else { |
94 | // qDebug("Not a dir: "+currentDir.canonicalPath()+fileL); | 94 | // qDebug("Not a dir: "+currentDir.canonicalPath()+fileL); |
95 | fileS.sprintf( "%10li", fi->size() ); | 95 | fileS.sprintf( "%10li", fi->size() ); |
96 | fileL.sprintf( "%s",fi->fileName().data() ); | 96 | fileL.sprintf( "%s",fi->fileName().data() ); |
97 | if( QDir(QDir::cleanDirPath(currentDir.canonicalPath()+"/"+fileL)).exists() ) { | 97 | if( QDir(QDir::cleanDirPath(currentDir.canonicalPath()+"/"+fileL)).exists() ) { |
98 | fileL+="/"; | 98 | fileL+="/"; |
99 | // qDebug(currentDir.canonicalPath()+fileL); | 99 | // qDebug( fileL); |
100 | } | 100 | } |
101 | } | 101 | } |
102 | item= new QListViewItem( ListView,fileL,fileS ); | 102 | item= new QListViewItem( ListView,fileL,fileS ); |
103 | ++it; | 103 | ++it; |
104 | } | 104 | } |
105 | ListView->setSorting( 2, FALSE); | 105 | ListView->setSorting( 2, FALSE); |