For UMS devices, add device (in brackets) after name. Should help devices with multiple partitions.
BUG: 413
This commit is contained in:
@@ -135,6 +135,8 @@
|
||||
81. Close temporary files after write, to ensure data is written. This fixes an
|
||||
issue where sometimes 0 byte files were written from CoverDialog.
|
||||
82. Use same order (URL, name) for both add stream-URL dialogs.
|
||||
83. For UMS devices, add device (in brackets) after name. Should help devices
|
||||
with multiple partitions.
|
||||
|
||||
1.2.2
|
||||
-----
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
#include <QFile>
|
||||
#include <QFileInfo>
|
||||
#include <QTextStream>
|
||||
#include <QDebug>
|
||||
|
||||
static const QLatin1String constSettingsFile("/.is_audio_player");
|
||||
static const QLatin1String constMusicFolderKey("audio_folder");
|
||||
@@ -39,6 +40,11 @@ UmsDevice::UmsDevice(MusicModel *m, Solid::Device &dev)
|
||||
: FsDevice(m, dev)
|
||||
, access(dev.as<Solid::StorageAccess>())
|
||||
{
|
||||
QStringList udiParts=dev.udi().split(QLatin1Char('/'), QString::SkipEmptyParts);
|
||||
|
||||
if (udiParts.length()>1) {
|
||||
setData(data()+QLatin1String(" (")+udiParts.last()+QLatin1Char(')'));
|
||||
}
|
||||
spaceInfo.setPath(access->filePath());
|
||||
setup();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user