chore: add back support for mistakenly deprecated G_VOLUME_IDENTIFIER_KIND_UNIX_DEVICE.

This commit is contained in:
Chris Xiong 2019-10-11 09:59:02 +08:00
parent 495e311260
commit 5fb3db906e
2 changed files with 2 additions and 0 deletions

View file

@ -31,6 +31,7 @@ class Volume;
enum DGioVolumeIdentifierType {
VOLUME_IDENTIFIER_TYPE_LABEL,
VOLUME_IDENTIFIER_TYPE_NFS_MOUNT,
VOLUME_IDENTIFIER_TYPE_UNIX_DEVICE,
VOLUME_IDENTIFIER_TYPE_UUID,
VOLUME_IDENTIFIER_TYPE_CLASS
};

View file

@ -123,6 +123,7 @@ QString DGioVolume::identifier(DGioVolumeIdentifierType id) const
const static QHash<DGioVolumeIdentifierType, std::string> idtmap = {
{DGioVolumeIdentifierType::VOLUME_IDENTIFIER_TYPE_LABEL, G_VOLUME_IDENTIFIER_KIND_LABEL},
{DGioVolumeIdentifierType::VOLUME_IDENTIFIER_TYPE_NFS_MOUNT, G_VOLUME_IDENTIFIER_KIND_NFS_MOUNT},
{DGioVolumeIdentifierType::VOLUME_IDENTIFIER_TYPE_UNIX_DEVICE, G_VOLUME_IDENTIFIER_KIND_UNIX_DEVICE},
{DGioVolumeIdentifierType::VOLUME_IDENTIFIER_TYPE_UUID, G_VOLUME_IDENTIFIER_KIND_UUID},
{DGioVolumeIdentifierType::VOLUME_IDENTIFIER_TYPE_CLASS, G_VOLUME_IDENTIFIER_KIND_CLASS}
};