diff options
author | Tom Marshall <tdm.code@gmail.com> | 2019-12-05 10:20:18 -0800 |
---|---|---|
committer | Tom Marshall <tdm.code@gmail.com> | 2019-12-05 10:22:28 -0800 |
commit | 13c4f098c6ddd7bd197dbae14ee4e164e5d2133f (patch) | |
tree | 3782aaac26f2c55f4bb5660661716714ba8cbd30 /ui.cpp | |
parent | 2a99d0cde307d964f40c4b4c18f42ce70b53b2c4 (diff) | |
download | android_bootable_recovery-13c4f098c6ddd7bd197dbae14ee4e164e5d2133f.tar.gz android_bootable_recovery-13c4f098c6ddd7bd197dbae14ee4e164e5d2133f.tar.bz2 android_bootable_recovery-13c4f098c6ddd7bd197dbae14ee4e164e5d2133f.zip |
recovery: Show slot indicator for A/B devices
When running on an A/B device, split the top version line horizontally
to show the Android version on the left and the boot slot on the right.
When not running on A/B device, center the Android version.
Change-Id: Ica18af5e46dadf1088fdfd6d23d96db090195a6a
Diffstat (limited to 'ui.cpp')
-rw-r--r-- | ui.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -88,6 +88,10 @@ RecoveryUI::RecoveryUI() char propval[PROPERTY_VALUE_MAX]; property_get("ro.build.version.release", propval, "(unknown)"); android_version_ = std::string("Android ") + propval; + property_get("ro.boot.slot_suffix", propval, ""); + if (propval[0] == '_') { + boot_slot_ = std::string("Slot ") + &propval[1]; + } property_get("ro.lineage.version", propval, "(unknown)"); lineage_version_ = std::string("LineageOS ") + propval; |