summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/WhatsNew.txt3
-rw-r--r--microkde/ofileselector_p.cpp34
2 files changed, 30 insertions, 7 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt
index eaf4b56..dd02be5 100644
--- a/bin/kdepim/WhatsNew.txt
+++ b/bin/kdepim/WhatsNew.txt
@@ -12,2 +12,5 @@ In the addressee selection dialog now the formatted name is shown, if not empty.
+Fixed in the file selector on the Zaurus the problem that symbolic links to files/dirs were ignored.
+Fixed the sorting for size in the file selector on the Z.
+
********** VERSION 2.1.7 ************
diff --git a/microkde/ofileselector_p.cpp b/microkde/ofileselector_p.cpp
index f85f8f4..e2af32b 100644
--- a/microkde/ofileselector_p.cpp
+++ b/microkde/ofileselector_p.cpp
@@ -158,6 +158,19 @@ OFileSelectorItem::OFileSelectorItem( QListView* view, const QPixmap& pixmap,
{
+
+ QString kind;
+ QString _path = path;
+ if ( isDir )
+ kind = "dir";
+ else
+ kind = "file";
setPixmap(0, pixmap );
- setText(1, path );
+ int arrow = path.find( "->" );
+ if (arrow > 0 ) {
+ kind += path.mid( arrow );
+ _path = path.left(arrow);
+ }
+ setText(1, _path );
setText(2, size );
setText(3, date );
+ setText(4, kind );
m_isDir = isDir;
@@ -192,3 +205,8 @@ QString OFileSelectorItem::key( int id, bool )const {
return ke;
- }else
+ } else if ( id == 2 ) {
+ QString sort = "00000000";
+ sort = sort.left( 9-text( 2 ).length()) + text( 2 );
+ return sort;
+
+ } else
return text( id );
@@ -347,5 +365,7 @@ void OFileViewFileListView::reread( bool all ) {
if( fi->isSymLink() ){
- QString file = fi->dirPath( true ) + "/" + fi->readLink();
- for( int i = 0; i<=4; i++) { // 5 tries to prevent dos
+ qDebug("SYMLINK ");
+ QString file = fi->readLink();
+ for( int i = 0; i<=5; i++) { // 5 tries to prevent dos
QFileInfo info( file );
+ qDebug("FILE %s ", file.latin1());
if( !info.exists() ){
@@ -360,3 +380,3 @@ void OFileViewFileListView::reread( bool all ) {
}else if( info.isSymLink() ){
- file = info.dirPath(true ) + "/" + info.readLink() ;
+ file = info.readLink() ;
break;
@@ -488,3 +508,3 @@ void OFileViewFileListView::addFile( QFileInfo* info, bool symlink ) {
if ( symlink )
- name = info->fileName() + " -> " + info->dirPath() + "/" + info->readLink();
+ name = info->fileName() + " -> " + info->readLink();
else{
@@ -514,3 +534,3 @@ void OFileViewFileListView::addDir( QFileInfo* info, bool symlink ) {
- name = symlink ? info->fileName() + " -> " + info->dirPath(true) + "/" + info->readLink() :
+ name = symlink ? info->fileName() + " -> " + info->readLink() :
info->fileName();