display text on sub-windows
This commit is contained in:
@ -46,13 +46,13 @@ uint32_t Drive::getPowerCycles(void)
|
||||
return u32PowerCycles;
|
||||
}
|
||||
|
||||
string Drive::sCapacityToText(){
|
||||
if(getCapacity() <= (999*1000000000U)){
|
||||
string Drive::sCapacityToText() {
|
||||
if(getCapacity() <= (999*1000000000U)) {
|
||||
// Less or even 999 GB --> GB
|
||||
return to_string(getCapacity() / 1000000000U) + " GB";
|
||||
return to_string(getCapacity() / 1000000000U) + " GB";
|
||||
}
|
||||
else{
|
||||
// More 999 GB --> TB
|
||||
else {
|
||||
// More 999 GB --> TB
|
||||
return to_string(getCapacity() / 1000000000000U) + " TB";
|
||||
}
|
||||
return "ERROR";
|
||||
|
Reference in New Issue
Block a user