diff --git a/main.cpp b/main.cpp index 522d66a..fa64d7f 100644 --- a/main.cpp +++ b/main.cpp @@ -76,11 +76,7 @@ int main(int argc, char *argv[]) // Checking if battery level is critical; if true (and if it is not charging), then display a "Please charge your eReader" splash and power off. if(global::deviceID != "emu\n") { if(isBatteryCritical() == true) { - string_checkconfig_ro("/sys/devices/platform/pmic_battery.1/power_supply/mc13892_bat/status"); - if(checkconfig_str_val == "Charging\n") { - ; - } - else { + if(!isUsbPluggedIn()) { global::battery::showCriticalBatteryAlert = true; QApplication a(argc, argv); alert w; diff --git a/mainwindow.cpp b/mainwindow.cpp index bfe86aa..21365d3 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -1174,7 +1174,7 @@ void MainWindow::resetFullWindow() { } void MainWindow::setRecentBooksLabelsTruncateThreshold() { - if(global::deviceID == "n705\n" or global::deviceID == "n905b\n" or global::deviceID == "n905c\n" or global::deviceID == "kt\n") { + if(global::deviceID == "n705\n" or global::deviceID == "n905\n" or global::deviceID == "kt\n") { truncateThreshold = 12; } else if(global::deviceID == "n613\n" or global::deviceID == "n873\n" or global::deviceID == "n236\n" or global::deviceID == "n437\n" or global::deviceID == "n306\n"){