summaryrefslogtreecommitdiffstats
path: root/tdeioslave/media/mediamanager
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2014-11-28 13:17:42 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2014-11-28 13:17:42 -0600
commit2c1d4ad359e90360708cffe70c298b264b302e49 (patch)
tree02f179c7d5f201f39c3036190142fa95c2288641 /tdeioslave/media/mediamanager
parenta7c3b934973a9435120596a6a577ab62e6fee348 (diff)
downloadtdebase-2c1d4ad359e90360708cffe70c298b264b302e49.tar.gz
tdebase-2c1d4ad359e90360708cffe70c298b264b302e49.zip
Hide udev hidden devices via the hidden file mechanism
This resolves Bug 2211
Diffstat (limited to 'tdeioslave/media/mediamanager')
-rw-r--r--tdeioslave/media/mediamanager/tdehardwarebackend.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/tdeioslave/media/mediamanager/tdehardwarebackend.cpp b/tdeioslave/media/mediamanager/tdehardwarebackend.cpp
index 56eab25b2..a7cbb2260 100644
--- a/tdeioslave/media/mediamanager/tdehardwarebackend.cpp
+++ b/tdeioslave/media/mediamanager/tdehardwarebackend.cpp
@@ -161,7 +161,7 @@ void TDEBackend::AddDevice(TDEStorageDevice * sdevice, bool allowNotification)
//
}
/* We also don't display devices that underlie other devices;
- /* e.g. the raw partition of a device mapper volume
+ * e.g. the raw partition of a device mapper volume
*/
else if (sdevice->checkDiskStatus(TDEDiskDeviceStatus::UsedByDevice)) {
//
@@ -181,6 +181,14 @@ void TDEBackend::AddDevice(TDEStorageDevice * sdevice, bool allowNotification)
}
}
+ // Hide udev hidden devices by default but allow the user to override if desired via Show Hidden Files
+ if (sdevice->checkDiskStatus(TDEDiskDeviceStatus::Hidden)) {
+ medium->setSoftHidden(true);
+ }
+ else {
+ medium->setSoftHidden(false);
+ }
+
// Insert medium into list
m_mediaList.addMedium(medium, allowNotification);