From b31f9ce6d150a264f584d9b38a54da0723fc249c Mon Sep 17 00:00:00 2001 From: Jerry Zhang Date: Mon, 21 May 2018 16:04:57 -0700 Subject: recovery: c++ify pthread use in UI Change pthread usage to std::mutex, lock_guard, unique_lock, thread, or condition_variable as appropriate. Test: Recovery works, recovery_component_test pass Bug: 78793464 Change-Id: Ibf0b1bbedcf0b6e32fc4ee6aaadd17f21b4d7077 --- screen_ui.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'screen_ui.h') diff --git a/screen_ui.h b/screen_ui.h index c3605161a..b76d4706e 100644 --- a/screen_ui.h +++ b/screen_ui.h @@ -17,7 +17,6 @@ #ifndef RECOVERY_SCREEN_UI_H #define RECOVERY_SCREEN_UI_H -#include #include #include @@ -192,7 +191,6 @@ class ScreenRecoveryUI : public RecoveryUI { GRSurface* GetCurrentFrame() const; GRSurface* GetCurrentText() const; - static void* ProgressThreadStartRoutine(void* data); void ProgressThreadLoop(); virtual void ShowFile(FILE*); @@ -297,7 +295,7 @@ class ScreenRecoveryUI : public RecoveryUI { std::string locale_; bool rtl_locale_; - pthread_mutex_t updateMutex; + std::mutex updateMutex; private: void SetLocale(const std::string&); -- cgit v1.2.3