summaryrefslogtreecommitdiffstats
path: root/tdecore
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2012-04-26 19:37:45 -0500
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2012-04-26 19:37:45 -0500
commit154beeca8e53f05bc292bf9674c9ced4fa5cc0f5 (patch)
tree147838d6d0d9df55591c42b790df36720416af91 /tdecore
parentc23ecdaa41327a9c577d1272a70186dece89ff38 (diff)
downloadtdelibs-154beeca8e53f05bc292bf9674c9ced4fa5cc0f5.tar.gz
tdelibs-154beeca8e53f05bc292bf9674c9ced4fa5cc0f5.zip
Handle tape drives properly
Classify parallel SCSI platform devices
Diffstat (limited to 'tdecore')
-rw-r--r--tdecore/tdehardwaredevices.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/tdecore/tdehardwaredevices.cpp b/tdecore/tdehardwaredevices.cpp
index 9a4bb0ccb..0b866d1b5 100644
--- a/tdecore/tdehardwaredevices.cpp
+++ b/tdecore/tdehardwaredevices.cpp
@@ -546,6 +546,9 @@ TQString TDEStorageDevice::friendlyDeviceType() {
if (isDiskOfType(TDEDiskDeviceType::Zip)) {
ret = i18n("Zip Drive");
}
+ if (isDiskOfType(TDEDiskDeviceType::Tape)) {
+ ret = i18n("Tape Drive");
+ }
if (isDiskOfType(TDEDiskDeviceType::HDD)) {
ret = i18n("Hard Disk Drive");
@@ -597,6 +600,9 @@ TQPixmap TDEStorageDevice::icon(KIcon::StdSizes size) {
if (isDiskOfType(TDEDiskDeviceType::Zip)) {
ret = DesktopIcon("zip_unmount", size);
}
+ if (isDiskOfType(TDEDiskDeviceType::Tape)) {
+ ret = DesktopIcon("tape_unmount", size);
+ }
if (isDiskOfType(TDEDiskDeviceType::HDD)) {
ret = DesktopIcon("hdd_unmount", size);
@@ -2250,7 +2256,7 @@ TDEDiskDeviceType::TDEDiskDeviceType classifyDiskType(udev_device* dev, const TQ
// Certain combinations of media flags should never be set at the same time as they don't make sense
// This block is needed as udev is more than happy to provide inconsistent data to us
- if ((disktype & TDEDiskDeviceType::Zip) || (disktype & TDEDiskDeviceType::Floppy) || (disktype & TDEDiskDeviceType::Jaz)) {
+ if ((disktype & TDEDiskDeviceType::Zip) || (disktype & TDEDiskDeviceType::Floppy) || (disktype & TDEDiskDeviceType::Jaz) || (disktype & TDEDiskDeviceType::Tape)) {
disktype = disktype & ~TDEDiskDeviceType::HDD;
}
@@ -3026,6 +3032,8 @@ TDEGenericDevice* TDEHardwareDevices::classifyUnknownDevice(udev_device* dev, TD
|| (devicesubsystem == "scsi_device")
|| (devicesubsystem == "scsi_generic")
|| (devicesubsystem == "scsi")
+ || (devicesubsystem == "spi_transport")
+ || (devicesubsystem == "spi_host")
|| (devicesubsystem == "ata_port")
|| (devicesubsystem == "ata_link")
|| (devicesubsystem == "ata_disk")