From a899453be686ea0d27a2551c385cfed139481f93 Mon Sep 17 00:00:00 2001 From: Spiros Date: Tue, 4 Jun 2024 03:08:13 +0300 Subject: [PATCH] Support Remaining_Lifetime_Perc --- mainwindow.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mainwindow.cpp b/mainwindow.cpp index a35c79b..9b738ef 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -333,6 +333,9 @@ void MainWindow::populateWindow(const QJsonObject &localObj, const QString &heal unsigned long long totalGbWritten = (lbaWritten * logicalBlockSize) / oneGB; totalWrites = QString::number(static_cast(totalGbWritten)) + " GB"; } + } else if (attrObj["name"] == "Remaining_Lifetime_Perc") { + int percentageUsed = attrObj["value"].toInt(); + percentage = QString::number(percentageUsed) + " %"; } else if (attrObj["name"] == "Media_Wearout_Indicator") { int percentageUsed = attrObj["value"].toInt(); percentage = QString::number(percentageUsed) + " %";