Add detection of ZFS (#752862)
Requires blkid from util-linux >= 2.15, released May 2009, for detection of ZFS. Bug 752862 - ZFS is not recognised
This commit is contained in:
parent
226f7ee8e8
commit
71715a1c29
|
@ -91,10 +91,11 @@ enum FILESYSTEM
|
||||||
FS_LINUX_SWRAID = 26,
|
FS_LINUX_SWRAID = 26,
|
||||||
FS_LINUX_SWSUSPEND = 27,
|
FS_LINUX_SWSUSPEND = 27,
|
||||||
FS_REFS = 28,
|
FS_REFS = 28,
|
||||||
|
FS_ZFS = 29,
|
||||||
|
|
||||||
// Partition space usage colours
|
// Partition space usage colours
|
||||||
FS_USED = 29,
|
FS_USED = 30,
|
||||||
FS_UNUSED = 30
|
FS_UNUSED = 31
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
enum SIZE_UNIT
|
enum SIZE_UNIT
|
||||||
|
|
|
@ -1612,6 +1612,8 @@ FILESYSTEM GParted_Core::detect_filesystem( PedDevice * lp_device, PedPartition
|
||||||
return FS_LINUX_SWSUSPEND ;
|
return FS_LINUX_SWSUSPEND ;
|
||||||
else if ( fsname == "ReFS" )
|
else if ( fsname == "ReFS" )
|
||||||
return FS_REFS;
|
return FS_REFS;
|
||||||
|
else if ( fsname == "zfs_member" )
|
||||||
|
return FS_ZFS;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Fallback to GParted simple internal file system detection
|
// Fallback to GParted simple internal file system detection
|
||||||
|
|
|
@ -108,6 +108,7 @@ Glib::ustring Utils::get_color( FILESYSTEM filesystem )
|
||||||
case FS_LINUX_SWRAID : return "#5A4733" ; // ~ dark brown
|
case FS_LINUX_SWRAID : return "#5A4733" ; // ~ dark brown
|
||||||
case FS_LINUX_SWSUSPEND : return "#884631" ; //red dark
|
case FS_LINUX_SWSUSPEND : return "#884631" ; //red dark
|
||||||
case FS_REFS : return "#1FC48D" ; // ~ medium aquamarine
|
case FS_REFS : return "#1FC48D" ; // ~ medium aquamarine
|
||||||
|
case FS_ZFS : return "#CC763D" ; // ~ darker orange
|
||||||
|
|
||||||
default : return "#000000" ;
|
default : return "#000000" ;
|
||||||
}
|
}
|
||||||
|
@ -283,6 +284,7 @@ Glib::ustring Utils::get_filesystem_string( FILESYSTEM filesystem )
|
||||||
case FS_LINUX_SWRAID : return "linux-raid" ;
|
case FS_LINUX_SWRAID : return "linux-raid" ;
|
||||||
case FS_LINUX_SWSUSPEND : return "linux-suspend" ;
|
case FS_LINUX_SWSUSPEND : return "linux-suspend" ;
|
||||||
case FS_REFS : return "refs" ;
|
case FS_REFS : return "refs" ;
|
||||||
|
case FS_ZFS : return "zfs" ;
|
||||||
|
|
||||||
default : return "" ;
|
default : return "" ;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue