From be844883631f2049238eb81e834cc2241c8d12b1 Mon Sep 17 00:00:00 2001 From: Youngjae Cho Date: Wed, 9 Aug 2023 20:27:27 +0900 Subject: [PATCH] plugin-api: deviced: Add display state It replaces existing enum state_t of the deviced. - S_START => DEVICED_DISPLAY_STATE_START - S_NORMAL => DEVICED_DISPLAY_STATE_ON - S_LCDON => DEVICED_DISPLAY_STATE_ON - S_LCDDIM => DEVICED_DISPLAY_STATE_DIM - S_LCDOFF => DEVICED_DISPLAY_STATE_OFF - S_STANDBY => removed - S_SLEEP => DEVICED_DISPLAY_STATE_SLEEP* - S_SUSPEND => removed - S_POWEROFF => removed [*] Technically, the DEVICED_DISPLAY_STATE_SLEEP cannot be a state of display. It should be a state of power, not display. However, current code indiscriminately uses S_SLEEP state as one of the display state. This will be fixed to make power module exclusively handle sleep, and the enum itself will be removed accordingly. The other removed enums are not being used. Change-Id: I1f22379e730311c211b36cd516a020eadd730938 Signed-off-by: Youngjae Cho --- .../include/syscommon-plugin-deviced-display-interface.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/plugin-api/deviced/include/syscommon-plugin-deviced-display-interface.h b/src/plugin-api/deviced/include/syscommon-plugin-deviced-display-interface.h index f47845e..9569061 100644 --- a/src/plugin-api/deviced/include/syscommon-plugin-deviced-display-interface.h +++ b/src/plugin-api/deviced/include/syscommon-plugin-deviced-display-interface.h @@ -31,6 +31,15 @@ extern "C" { #define DEVICED_DISPLAY_ATTR_INT_GET_MAX_BRIGHTNESS (1ULL << 0) +enum deviced_display_state { + DEVICED_DISPLAY_STATE_START, + DEVICED_DISPLAY_STATE_ON, + DEVICED_DISPLAY_STATE_DIM, + DEVICED_DISPLAY_STATE_OFF, + DEVICED_DISPLAY_STATE_SLEEP, + DEVICED_DISPLAY_STATE_END, +}; + #ifdef __cplusplus } #endif -- 2.34.1