browse_server=Server to request browse list from,3,localhost
long_fstypes=Show long filesystem type names,1,1-Yes,0-No
sort_mode=Sort filesystems by,1,2-Mount point,1-Type,0-Order in files
+show_used=Show used disk space in filesystems list,1,1-Yes,0-No
delete_under=Delete directory when un-mounting if under,3,Never delete
line2=System configuration,11
fstab_file=File listing filesystems mounted at boot time,0
print &ui_columns_start([ $text{'index_dir'},
$text{'index_type'},
$text{'index_dev'},
- $text{'index_used'},
+ $config{'show_used'} ? ( $text{'index_used'} )
+ : ( ),
$text{'index_use'},
$text{'index_perm'} ], 100);
foreach $m (@visible) {
$fsn .= " ($minfo[2])" if (uc($fsn) ne uc($minfo[2]));
push(@cols, $minfo[2] eq "*" ? $text{'index_auto'} : $fsn);
push(@cols, &device_name($minfo[1]));
- ($total, $free) = &disk_space($minfo[2],$minfo[0]);
- if ($total) {
- $pc = int(100*($total-$free) / $total);
- push(@cols, $pc >= 99 ? "<font color=red>$pc %</font>" :
- $pc >= 95 ? "<font color=orange>$pc %</font>" : $pc."%");
- }
- else {
- push(@cols, "");
+ if ($config{'show_used'}) {
+ # Add disk space used column
+ ($total, $free) = &disk_space($minfo[2],$minfo[0]);
+ if ($total) {
+ $pc = int(100*($total-$free) / $total);
+ push(@cols,
+ $pc >= 99 ? "<font color=red>$pc %</font>" :
+ $pc >= 95 ? "<font color=orange>$pc %</font>" :
+ $pc."%");
+ }
+ else {
+ push(@cols, "");
+ }
}
if (&can_edit_fs(@minfo)) {
push(@cols,