summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--library/applnk.cpp2
-rw-r--r--library/global.cpp4
-rw-r--r--library/lnkproperties.cpp7
-rw-r--r--library/storage.cpp14
4 files changed, 16 insertions, 11 deletions
diff --git a/library/applnk.cpp b/library/applnk.cpp
index 5185b5f..778ccab 100644
--- a/library/applnk.cpp
+++ b/library/applnk.cpp
@@ -340,7 +340,7 @@ QString AppLnk::linkFile() const
if ( type().contains('/') ) {
StorageInfo storage;
const FileSystem *fs = storage.fileSystemOf( that->mFile );
- if ( fs && fs->isRemovable() ) {
+ if ( fs && ( fs->isRemovable() || fs->disk() == "/dev/mtdblock6" || fs->disk() == "tmpfs" ) ) {
that->mLinkFile = fs->path();
} else
that->mLinkFile = getenv( "HOME" );
diff --git a/library/global.cpp b/library/global.cpp
index edb7b85..ab27b3f 100644
--- a/library/global.cpp
+++ b/library/global.cpp
@@ -681,6 +681,10 @@ void Global::findDocuments(DocLnkSet* folder, const QString &mimefilter)
continue;
DocLnkSet ide( path, mimefilter );
folder->appendFrom(ide);
+ } else if ( (*it)->disk() == "/dev/mtdblock6" || (*it)->disk() == "tmpfs" ) {
+ QString path = (*it)->path() + "/Documents";
+ DocLnkSet ide( path, mimefilter );
+ folder->appendFrom(ide);
}
}
}
diff --git a/library/lnkproperties.cpp b/library/lnkproperties.cpp
index e8baca6..c020328 100644
--- a/library/lnkproperties.cpp
+++ b/library/lnkproperties.cpp
@@ -173,15 +173,16 @@ void LnkProperties::setupLocations()
if ( (*it)->availBlocks() * (*it)->blockSize() > fileSize + 10000 ) {
if ( (*it)->isRemovable() ||
(*it)->disk() == "/dev/mtdblock1" ||
- (*it)->disk() == "/dev/mtdblock/1" || (*it)->disk().left(13) == "/dev/mtdblock" ) {
+ (*it)->disk() == "/dev/mtdblock/1" || (*it)->disk().left(13) == "/dev/mtdblock" ||
+ (*it)->disk() == "/dev/mtdblock6" || (*it)->disk() == "tmpfs" ) {
d->locationCombo->insertItem( (*it)->name(), index );
- locations.append( ((*it)->isRemovable() ? (*it)->path() : homeDir) );
+ locations.append( ((*it)->isRemovable() || (*it)->disk() == "/dev/mtdblock6" || (*it)->disk() == "tmpfs" ? (*it)->path() : homeDir) );
if ( lnk->file().contains( (*it)->path() ) ) {
d->locationCombo->setCurrentItem( index );
currentLocation = index;
}
index++;
- } else if ( (*it)->name().contains( "Hard Disk") &&
+ } else if ( (*it)->name().contains( tr("Hard Disk") ) &&
homeDir.contains( (*it)->path() ) &&
(*it)->path().length() > hardDiskHome.length() ) {
hardDiskHome = (*it)->name();
diff --git a/library/storage.cpp b/library/storage.cpp
index 2d996fa..13639fe 100644
--- a/library/storage.cpp
+++ b/library/storage.cpp
@@ -105,7 +105,7 @@ void StorageInfo::update()
QString fs = me->mnt_fsname;
if ( fs.left(7)=="/dev/hd" || fs.left(7)=="/dev/sd"
|| fs.left(8)=="/dev/mtd" || fs.left(9) == "/dev/mmcd"
- || fs.left(8)=="/dev/ram" || fs.left(5)=="tmpfs" )
+ || fs.left(5)=="tmpfs" )
{
n++;
curdisks.append(fs);
@@ -145,19 +145,19 @@ void StorageInfo::update()
humanname = tr("SD Card");
removable = TRUE;
} else if ( disk.left(7) == "/dev/hd" )
- humanname = tr("Hard Disk") + " " + humanname.mid(7);
+ humanname = tr("Hard Disk") + " " + disk.mid(7);
else if ( disk.left(7) == "/dev/sd" )
- humanname = tr("SCSI Hard Disk") + " " + humanname.mid(7);
+ humanname = tr("SCSI Hard Disk") + " " + disk.mid(7);
else if ( disk.left(14) == "/dev/mtdblock6" ) //openzaurus ramfs
- humanname = tr("Ram FS") + " " + humanname.mid(14);
+ humanname = tr("Internal Memory");
else if ( disk == "/dev/mtdblock1" || humanname == "/dev/mtdblock/1" )
humanname = tr("Internal Storage");
else if ( disk.left(14) == "/dev/mtdblock/" )
- humanname = tr("Internal Storage") + " " + humanname.mid(14);
+ humanname = tr("Internal Storage") + " " + disk.mid(14);
else if ( disk.left(13) == "/dev/mtdblock" )
- humanname = tr("Internal Storage") + " " + humanname.mid(13);
+ humanname = tr("Internal Storage") + " " + disk.mid(13);
else if ( disk.left(5) == "tmpfs" ) //ipaqs /mnt/ramfs
- humanname = tr("Ram FS") + " " + humanname.mid(5);
+ humanname = tr("Internal Memory");
FileSystem *fs = new FileSystem( disk, *fsit, humanname, removable, opts );
mFileSystems.append( fs );
}