From 6dab4b2a9395c3a9743f99fe1d49a54254166bbb Mon Sep 17 00:00:00 2001 From: Changyeon Lee Date: Tue, 8 Feb 2022 19:29:52 +0900 Subject: [PATCH] e_hwc windows: update state of root target window in e_hwc_windows_render if target window of all hwc do not have device state, none state is set to root target window and it does not render. Change-Id: I72f75ed0aad1cbd93b92bd8d1f696e8675395878 --- src/bin/e_hwc_windows.c | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/src/bin/e_hwc_windows.c b/src/bin/e_hwc_windows.c index ad03f59f37..0a0ff2fc3c 100644 --- a/src/bin/e_hwc_windows.c +++ b/src/bin/e_hwc_windows.c @@ -3219,6 +3219,34 @@ e_hwc_windows_deinit(void) e_hwc_window_deinit(); } +static void +_e_hwc_windows_root_target_window_state_update(E_Hwc_Window_Target *root_target_hwc_window) +{ + E_Output *output; + Eina_List *l; + E_Hwc_Window_State state; + E_Hwc_Window_State root_state = E_HWC_WINDOW_STATE_NONE; + + EINA_SAFETY_ON_NULL_RETURN(e_comp); + EINA_SAFETY_ON_NULL_RETURN(e_comp->e_comp_screen); + + EINA_LIST_FOREACH(e_comp->e_comp_screen->outputs, l, output) + { + if (!e_output_connected(output)) continue; + if (!output->hwc) continue; + if (!output->hwc->target_hwc_window) continue; + + state = e_hwc_window_state_get((E_Hwc_Window *)output->hwc->target_hwc_window); + if (state == E_HWC_WINDOW_STATE_DEVICE) + { + root_state = E_HWC_WINDOW_STATE_DEVICE; + break; + } + } + + _e_hwc_windows_target_state_set(root_target_hwc_window, root_state); +} + EINTERN Eina_Bool e_hwc_windows_render(E_Hwc *hwc) { @@ -3233,6 +3261,8 @@ e_hwc_windows_render(E_Hwc *hwc) target_window = (E_Hwc_Window *)target_hwc_window; EINA_SAFETY_ON_NULL_RETURN_VAL(target_window->queue, EINA_FALSE); + _e_hwc_windows_root_target_window_state_update(target_hwc_window); + if ((e_hwc_window_state_get(target_window) == E_HWC_WINDOW_STATE_NONE) || ((hwc->pp_set) && (hwc->pp_hwc_window))) { -- 2.34.1