feat: added a low power mode state to the Battery popup window (#1024)

This commit is contained in:
Serhiy Mytrovtsiy
2022-08-19 19:12:08 +02:00
parent a7863f1c42
commit a28a3b8ef6
33 changed files with 120 additions and 17 deletions

View File

@@ -18,6 +18,7 @@ struct Battery_Usage: value_t {
var state: String? = nil
var isCharged: Bool = false
var isCharging: Bool = false
var isLowPowerMode: Bool? = false
var level: Double = 0
var cycles: Int = 0
var health: Int = 0
@@ -137,7 +138,8 @@ public class Battery: Module {
widget.setValue(
percentage: value.level ,
ACStatus: value.powerSource != "Battery Power",
isCharging: value.isCharging ,
isCharging: value.isCharging,
lowPowerMode: value.isLowPowerMode,
time: value.timeToEmpty == 0 && value.timeToCharge != 0 ? value.timeToCharge : value.timeToEmpty
)
default: break

View File

@@ -19,7 +19,13 @@ internal class Popup: NSView, Popup_p {
private let dashboardHeight: CGFloat = 90
private let detailsHeight: CGFloat = (22 * 7) + Constants.Popup.separatorHeight
private var detailsHeight: CGFloat {
var count: CGFloat = 7
if #available(macOS 12.0, *) {
count += 1
}
return (22 * count) + Constants.Popup.separatorHeight
}
private let batteryHeight: CGFloat = (22 * 4) + Constants.Popup.separatorHeight
private let adapterHeight: CGFloat = (22 * 2) + Constants.Popup.separatorHeight
private let processHeight: CGFloat = (22 * 1)
@@ -38,6 +44,7 @@ internal class Popup: NSView, Popup_p {
private var capacityField: NSTextField? = nil
private var cyclesField: NSTextField? = nil
private var lastChargeField: NSTextField? = nil
private var lowPowerModeField: NSTextField? = nil
private var amperageField: NSTextField? = nil
private var voltageField: NSTextField? = nil
@@ -76,9 +83,9 @@ internal class Popup: NSView, Popup_p {
x: 0,
y: 0,
width: Constants.Popup.width,
height: self.dashboardHeight + self.detailsHeight + self.batteryHeight + self.adapterHeight
height: self.dashboardHeight + self.batteryHeight + self.adapterHeight
))
self.setFrameSize(NSSize(width: self.frame.width, height: self.frame.height+self.processesHeight))
self.setFrameSize(NSSize(width: self.frame.width, height: self.frame.height + self.detailsHeight + self.processesHeight))
let gridView: NSGridView = NSGridView(frame: NSRect(x: 0, y: 0, width: self.frame.width, height: self.frame.height))
gridView.rowSpacing = 0
@@ -145,18 +152,24 @@ internal class Popup: NSView, Popup_p {
private func initDetails() -> NSView {
let view: NSView = NSView(frame: NSRect(x: 0, y: 0, width: self.frame.width, height: self.detailsHeight))
let separator = separatorView(localizedString("Details"), origin: NSPoint(x: 0, y: self.detailsHeight-Constants.Popup.separatorHeight), width: self.frame.width)
let container: NSView = NSView(frame: NSRect(x: 0, y: 0, width: self.frame.width, height: separator.frame.origin.y))
self.levelField = popupRow(container, n: 6, title: "\(localizedString("Level")):", value: "").1
self.sourceField = popupRow(container, n: 5, title: "\(localizedString("Source")):", value: "").1
let t = self.labelValue(container, n: 4, title: "\(localizedString("Time")):", value: "")
let container: NSStackView = NSStackView(frame: NSRect(x: 0, y: 0, width: view.frame.width, height: separator.frame.origin.y))
container.orientation = .vertical
container.spacing = 0
self.levelField = popupRow(container, title: "\(localizedString("Level")):", value: "").1
self.sourceField = popupRow(container, title: "\(localizedString("Source")):", value: "").1
self.healthField = popupRow(container, title: "\(localizedString("Health")):", value: "").1
self.capacityField = popupRow(container, title: "\(localizedString("Capacity")):", value: "").1
self.capacityField?.toolTip = localizedString("maximum / designed")
self.cyclesField = popupRow(container, title: "\(localizedString("Cycles")):", value: "").1
let t = self.labelValue(container, title: "\(localizedString("Time")):", value: "")
self.timeLabelField = t.0
self.timeField = t.1
self.healthField = popupRow(container, n: 3, title: "\(localizedString("Health")):", value: "").1
self.capacityField = popupRow(container, n: 2, title: "\(localizedString("Capacity")):", value: "").1
self.capacityField?.toolTip = localizedString("maximum / designed")
self.cyclesField = popupRow(container, n: 1, title: "\(localizedString("Cycles")):", value: "").1
self.lastChargeField = popupRow(container, n: 0, title: "\(localizedString("Last charge")):", value: "").1
self.lastChargeField = popupRow(container, title: "\(localizedString("Last charge")):", value: "").1
if #available(macOS 12.0, *) {
self.lowPowerModeField = popupRow(container, title: "\(localizedString("Low power mode")):", value: localizedString("Unknown")).1
}
view.addSubview(separator)
view.addSubview(container)
@@ -215,15 +228,21 @@ internal class Popup: NSView, Popup_p {
return view
}
private func labelValue(_ view: NSView, n: CGFloat, title: String, value: String) -> (NSTextField, NSTextField) {
let rowView: NSView = NSView(frame: NSRect(x: 0, y: 22*n, width: view.frame.width, height: 22))
private func labelValue(_ view: NSView, title: String, value: String) -> (NSTextField, NSTextField) {
let rowView: NSView = NSView(frame: NSRect(x: 0, y: 0, width: view.frame.width, height: 22))
let labelView: LabelField = LabelField(frame: NSRect(x: 0, y: (22-15)/2, width: view.frame.width/2, height: 15), title)
let valueView: ValueField = ValueField(frame: NSRect(x: view.frame.width/2, y: (22-16)/2, width: view.frame.width/2, height: 16), value)
rowView.addSubview(labelView)
rowView.addSubview(valueView)
view.addSubview(rowView)
if let view = view as? NSStackView {
rowView.heightAnchor.constraint(equalToConstant: rowView.bounds.height).isActive = true
view.addArrangedSubview(rowView)
} else {
view.addSubview(rowView)
}
return (labelView, valueView)
}
@@ -289,6 +308,10 @@ internal class Popup: NSView, Popup_p {
self.lastChargeField?.toolTip = localizedString("Unknown")
}
if let powerMode = value.isLowPowerMode {
self.lowPowerModeField?.stringValue = powerMode ? localizedString("Enabled") : localizedString("Disabled")
}
self.amperageField?.stringValue = "\(abs(value.amperage)) mA"
self.voltageField?.stringValue = "\(value.voltage.roundTo(decimalPlaces: 2)) V"
let batteryPower = value.voltage * (Double(abs(value.amperage))/1000)

View File

@@ -39,6 +39,10 @@ internal class UsageReader: Reader<Battery_Usage> {
CFRunLoopAddSource(self.loop, source, .defaultMode)
self.read()
if #available(macOS 12.0, *) {
NotificationCenter.default.addObserver(self, selector: #selector(self.lowModeChanged), name: Notification.Name.NSProcessInfoPowerStateDidChange, object: nil)
}
}
public override func stop() {
@@ -50,6 +54,10 @@ internal class UsageReader: Reader<Battery_Usage> {
CFRunLoopRemoveSource(runLoop, source, .defaultMode)
}
deinit {
NotificationCenter.default.removeObserver(self)
}
public override func read() {
let psInfo = IOPSCopyPowerSourcesInfo().takeRetainedValue()
let psList = IOPSCopyPowerSourcesList(psInfo).takeRetainedValue() as [CFTypeRef]
@@ -63,6 +71,9 @@ internal class UsageReader: Reader<Battery_Usage> {
self.usage.powerSource = list[kIOPSPowerSourceStateKey] as? String ?? "AC Power"
self.usage.isCharged = list[kIOPSIsChargedKey] as? Bool ?? false
self.usage.isCharging = self.getBoolValue("IsCharging" as CFString) ?? false
if #available(macOS 12.0, *) {
self.usage.isLowPowerMode = ProcessInfo.processInfo.isLowPowerModeEnabled
}
self.usage.level = Double(list[kIOPSCurrentCapacityKey] as? Int ?? 0) / 100
if let time = list[kIOPSTimeToEmptyKey] as? Int {
@@ -139,6 +150,13 @@ internal class UsageReader: Reader<Battery_Usage> {
}
return nil
}
@objc private func lowModeChanged() {
if #available(macOS 12.0, *) {
self.usage.isLowPowerMode = ProcessInfo.processInfo.isLowPowerModeEnabled
self.callback(self.usage)
}
}
}
public class ProcessReader: Reader<[TopProcess]> {

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Център";
"Right alignment" = "Дясно";
"Dashboard" = "Табло";
"Enabled" = "Enabled";
"Disabled" = "Изключено";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Последно зареждане";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Батерия за показване";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Centre";
"Right alignment" = "Dreta";
"Dashboard" = "Panell";
"Enabled" = "Enabled";
"Disabled" = "Desactivat";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Última càrrega";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Bateria a mostrar";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Zarovnat na střed";
"Right alignment" = "Zarovnat doprava";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Deaktivováno";
"Silent" = "Tichý";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Poslední nabití";
"Capacity" = "Kapicita";
"maximum / designed" = "maximum / výrobní";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Baterie k zobrazení";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Midterjusteret";
"Right alignment" = "Højrejusteret";
"Dashboard" = "Instrumentbræt";
"Enabled" = "Enabled";
"Disabled" = "Deaktiveret";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Sidst opladt";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Batteri der vises";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Mitte";
"Right alignment" = "Rechts";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Deaktiviert";
"Silent" = "Leise";
"Units" = "Einheit";
@@ -313,6 +314,7 @@
"Last charge" = "Letzte Ladung";
"Capacity" = "Kapazität";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Angezeigter Akku";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Κεντρική";
"Right alignment" = "Δεξιά";
"Dashboard" = "Ταμπλό";
"Enabled" = "Enabled";
"Disabled" = "Απενεργοποιημένο";
"Silent" = "Σίγαση";
"Units" = "Μονάδες";
@@ -313,6 +314,7 @@
"Last charge" = "Τελευταία φόρτιση";
"Capacity" = "Χωρητικότητα";
"maximum / designed" = "Μέγιστη / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Μπαταρία προς εμφάνιση";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Center";
"Right alignment" = "Right";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Disabled";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Last charge";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Battery to show";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Center";
"Right alignment" = "Right";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Disabled";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Última carga";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Battery to show";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Centre";
"Right alignment" = "Droite";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Disabled";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Dernière charge";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Batterie à montrer";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "מרכז";
"Right alignment" = "ימין";
"Dashboard" = "דאשבורד";
"Enabled" = "Enabled";
"Disabled" = "חסימה";
"Silent" = "שקט";
"Units" = "יחידות";
@@ -313,6 +314,7 @@
"Last charge" = "טעינה אחרונה";
"Capacity" = "קיבולת";
"maximum / designed" = "מקסימום / עיצוב";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "סוללה להצגה";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Centrirano";
"Right alignment" = "Desno";
"Dashboard" = "Pregledna ploča";
"Enabled" = "Enabled";
"Disabled" = "Deaktivirano";
"Silent" = "Tiho";
"Units" = "Jedinice";
@@ -313,6 +314,7 @@
"Last charge" = "Zadnje punjenje";
"Capacity" = "Kapacitet";
"maximum / designed" = "maksimalni / projektirani";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Baterija";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Középre igazítás";
"Right alignment" = "Jobbra igazítás";
"Dashboard" = "Irányítópult";
"Enabled" = "Enabled";
"Disabled" = "Kikapcsolva";
"Silent" = "Néma";
"Units" = "Mértékegységek";
@@ -313,6 +314,7 @@
"Last charge" = "Utolsó töltés";
"Capacity" = "Kapacitás";
"maximum / designed" = "maximum / gyári";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Akkumulátor megjelenítése";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Alignment tengah";
"Right alignment" = "Alignment kanan";
"Dashboard" = "Dasbor";
"Enabled" = "Enabled";
"Disabled" = "Dinonaktifkan";
"Silent" = "Hening";
"Units" = "Unit";
@@ -313,6 +314,7 @@
"Last charge" = "Terakhir diisi";
"Capacity" = "Kapasitas";
"maximum / designed" = "maksimal / dirancang";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Baterai untuk ditampilkan";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Centro";
"Right alignment" = "Destra";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Disabilitato";
"Silent" = "Silenzioso";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Ultima carica";
"Capacity" = "Capacità";
"maximum / designed" = "massima / progettata";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Batteria da mostrare";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "中央揃え";
"Right alignment" = "右揃え";
"Dashboard" = "ダッシュボード";
"Enabled" = "Enabled";
"Disabled" = "無効";
"Silent" = "自動(サイレント)";
"Units" = "単位";
@@ -313,6 +314,7 @@
"Last charge" = "最後の充電から";
"Capacity" = "容量";
"maximum / designed" = "最大 / 規格";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "バッテリー残量を表示するデバイス";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "가운데";
"Right alignment" = "오른쪽";
"Dashboard" = "대시보드";
"Enabled" = "Enabled";
"Disabled" = "사용 안 함";
"Silent" = "조용한";
"Units" = "단위";
@@ -313,6 +314,7 @@
"Last charge" = "마지막 충전";
"Capacity" = "용량";
"maximum / designed" = "최대 / 설계";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "표시할 배터리";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Sentrum";
"Right alignment" = "Høyre";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Disabled";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Siste lading";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Battery å vise";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Midden";
"Right alignment" = "Rechts";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Uitgeschakeld";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Laatste oplading";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Battery to show";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Centrum";
"Right alignment" = "Do prawej";
"Dashboard" = "Dashboard";
"Enabled" = "Włączone";
"Disabled" = "Wyłączone";
"Silent" = "Tryb cichy";
"Units" = "Jednostki";
@@ -313,6 +314,7 @@
"Last charge" = "Ostatnie ładowanie";
"Capacity" = "Pojemność";
"maximum / designed" = "maksymalna / zaprojektowana";
"Low power mode" = "Niskie zużycie energii";
// Bluetooth
"Battery to show" = "Bateria do wyświetlenia";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Center";
"Right alignment" = "Right";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Disabled";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Última carga";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Battery to show";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Center";
"Right alignment" = "Right";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Disabled";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Última carga";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Battery to show";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Center";
"Right alignment" = "Right";
"Dashboard" = "Dashboard";
"Enabled" = "Enabled";
"Disabled" = "Disabled";
"Silent" = "Silent";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Ultima încărcare";
"Capacity" = "Capacity";
"maximum / designed" = "maximum / designed";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Battery to show";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "по центру";
"Right alignment" = "по правому";
"Dashboard" = "Dashboard";
"Enabled" = "Включено";
"Disabled" = "Отключено";
"Silent" = "Бесшумно";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Последняя зарядка";
"Capacity" = "Емкость";
"maximum / designed" = "максимальная / расчетная";
"Low power mode" = "Режим пониженного энергопотребления";
// Bluetooth
"Battery to show" = "Активная батарея";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Sredina";
"Right alignment" = "Desno";
"Dashboard" = "Nadzorna plošča";
"Enabled" = "Enabled";
"Disabled" = "Onemogočeno";
"Silent" = "Tiho";
"Units" = "Enote";
@@ -313,6 +314,7 @@
"Last charge" = "Zadnje polnjenje";
"Capacity" = "Kapaciteta";
"maximum / designed" = "največja / predvidena";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Prikaz baterije";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Centrerad";
"Right alignment" = "Höger";
"Dashboard" = "Kontrollpanel";
"Enabled" = "Enabled";
"Disabled" = "Inaktiverad";
"Silent" = "Tyst";
"Units" = "Enheter";
@@ -313,6 +314,7 @@
"Last charge" = "Senaste laddning";
"Capacity" = "Kapacitet";
"maximum / designed" = "nuvarande / ursprunglig";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Batteri att visa";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Ortaya hizalama";
"Right alignment" = "Sağa hizalama";
"Dashboard" = "Panel";
"Enabled" = "Enabled";
"Disabled" = "Devre dışı";
"Silent" = "Sessiz";
"Units" = "Birimler";
@@ -313,6 +314,7 @@
"Last charge" = "Son şarj";
"Capacity" = "Kapasite";
"maximum / designed" = "maksimum / orijinal";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Gösterilecek pil";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "По центру";
"Right alignment" = "Праворуч";
"Dashboard" = "Dashboard";
"Enabled" = "Включено";
"Disabled" = "Виключено";
"Silent" = "Безшумно";
"Units" = "Одиниці";
@@ -313,6 +314,7 @@
"Last charge" = "Остання зарядка";
"Capacity" = "Ємність";
"maximum / designed" = "максимальна / запроектована";
"Low power mode" = "Режим низької потужності";
// Bluetooth
"Battery to show" = "Активна батарея";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "Giữa";
"Right alignment" = "Phải";
"Dashboard" = "Bảng điều khiển";
"Enabled" = "Enabled";
"Disabled" = "Vô hiệu hóa";
"Silent" = "Im lặng";
"Units" = "Units";
@@ -313,6 +314,7 @@
"Last charge" = "Lần sạc cuối cùng";
"Capacity" = "Dung tích";
"maximum / designed" = "tối đa / thiết kế";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "Pin hiển thị";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "居中";
"Right alignment" = "右对齐";
"Dashboard" = "仪表盘";
"Enabled" = "Enabled";
"Disabled" = "已停用";
"Silent" = "运行时静默";
"Units" = "单位";
@@ -313,6 +314,7 @@
"Last charge" = "最后一次充电";
"Capacity" = "容量";
"maximum / designed" = "最大值 / 设计值";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "显示的设备";

View File

@@ -57,6 +57,7 @@
"Center alignment" = "置中對齊";
"Right alignment" = "靠右對齊";
"Dashboard" = "儀表板";
"Enabled" = "Enabled";
"Disabled" = "已停用";
"Silent" = "靜止";
"Units" = "單位";
@@ -313,6 +314,7 @@
"Last charge" = "最近一次充電";
"Capacity" = "容量";
"maximum / designed" = "最大容量 / 設計容量";
"Low power mode" = "Low power mode";
// Bluetooth
"Battery to show" = "顯示藍牙裝置的電池電量";