summaryrefslogtreecommitdiffstats
path: root/wear_ui.cpp
diff options
context:
space:
mode:
authorTao Bao <tbao@google.com>2018-05-04 01:27:28 +0200
committerandroid-build-merger <android-build-merger@google.com>2018-05-04 01:27:28 +0200
commit3777c4b8597f4a6fc46e57305d7aa33040c3b7bf (patch)
treeed48a00a97ba96e5388d1b3420ac425b81b35217 /wear_ui.cpp
parentMerge "updater_sample: update tests" am: 219445a320 (diff)
parentMerge "Move menu headers/items to std::vector<std::string>." (diff)
downloadandroid_bootable_recovery-3777c4b8597f4a6fc46e57305d7aa33040c3b7bf.tar
android_bootable_recovery-3777c4b8597f4a6fc46e57305d7aa33040c3b7bf.tar.gz
android_bootable_recovery-3777c4b8597f4a6fc46e57305d7aa33040c3b7bf.tar.bz2
android_bootable_recovery-3777c4b8597f4a6fc46e57305d7aa33040c3b7bf.tar.lz
android_bootable_recovery-3777c4b8597f4a6fc46e57305d7aa33040c3b7bf.tar.xz
android_bootable_recovery-3777c4b8597f4a6fc46e57305d7aa33040c3b7bf.tar.zst
android_bootable_recovery-3777c4b8597f4a6fc46e57305d7aa33040c3b7bf.zip
Diffstat (limited to 'wear_ui.cpp')
-rw-r--r--wear_ui.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/wear_ui.cpp b/wear_ui.cpp
index d21f83542..f157d3ca3 100644
--- a/wear_ui.cpp
+++ b/wear_ui.cpp
@@ -20,6 +20,7 @@
#include <string.h>
#include <string>
+#include <vector>
#include <android-base/properties.h>
#include <android-base/strings.h>
@@ -88,13 +89,12 @@ void WearRecoveryUI::update_progress_locked() {
void WearRecoveryUI::SetStage(int /* current */, int /* max */) {}
-void WearRecoveryUI::StartMenu(const char* const* headers, const char* const* items,
- int initial_selection) {
+void WearRecoveryUI::StartMenu(const std::vector<std::string>& headers,
+ const std::vector<std::string>& items, size_t initial_selection) {
pthread_mutex_lock(&updateMutex);
if (text_rows_ > 0 && text_cols_ > 0) {
menu_ = std::make_unique<Menu>(scrollable_menu_, text_rows_ - kMenuUnusableRows - 1,
text_cols_ - 1, headers, items, initial_selection);
-
update_screen_locked();
}
pthread_mutex_unlock(&updateMutex);