}
}
+static void
+_e_hwc_window_client_subsurface_present_sync(E_Client *ec)
+{
+ E_Hwc_Window_State state;
+ Eina_List *l;
+ E_Client *subc;
+
+ if (!ec->hwc_window) return;
+
+ state = e_hwc_window_accepted_state_get(ec->hwc_window);
+ if ((state == E_HWC_WINDOW_STATE_DEVICE) || (state == E_HWC_WINDOW_STATE_VIDEO))
+ e_hwc_window_present_sync(ec->hwc_window);
+
+ if (!ec->comp_data) return;
+
+ EINA_LIST_FOREACH(ec->comp_data->sub.below_list_pending, l, subc)
+ {
+ if (!subc->hwc_window) continue;
+ _e_hwc_window_client_subsurface_present_sync(subc);
+ }
+
+ EINA_LIST_FOREACH(ec->comp_data->sub.below_list, l, subc)
+ {
+ if (!subc->hwc_window) continue;
+ _e_hwc_window_client_subsurface_present_sync(subc);
+ }
+}
+
static void
_e_hwc_window_free(E_Hwc_Window *hwc_window)
{
_e_hwc_window_view_cb_move(struct wl_listener *listener, void *data)
{
E_Hwc_Window *hwc_window;
+ Eina_List *l;
+ E_Client *subc;
+ E_Hwc_Window_State state;
+ E_Client *ec;
hwc_window = wl_container_of(listener, hwc_window, move_listener);
if (!hwc_window) return;
if ((hwc_window->evas_visible) && (e_hwc_window_client_geometry_visible_get(hwc_window)))
e_hwc_window_changed_set(hwc_window, E_HWC_WINS_CHANGED_WIN_VISIBLE);
}
+
+ ec = hwc_window->ec;
+ if (!ec) return;
+
+ if (!e_comp_wl_video_subsurface_has(ec) && !e_comp_wl_normal_subsurface_has(ec))
+ return;
+
+ /* if window is device state, sync is not needed */
+ state = e_hwc_window_accepted_state_get(hwc_window);
+ if (state != E_HWC_WINDOW_STATE_CLIENT) return;
+
+ EINA_LIST_FOREACH(ec->comp_data->sub.below_list_pending, l, subc)
+ {
+ if (!subc->hwc_window) continue;
+ _e_hwc_window_client_subsurface_present_sync(subc);
+ }
+
+ EINA_LIST_FOREACH(ec->comp_data->sub.below_list, l, subc)
+ {
+ if (!subc->hwc_window) continue;
+ _e_hwc_window_client_subsurface_present_sync(subc);
+ }
}
static void
e_hwc_window_client_type_override(hwc_window);
}
-static void
-_e_hwc_window_client_subsurface_present_sync(E_Client *ec)
-{
- E_Hwc_Window_State state;
- Eina_List *l;
- E_Client *subc;
-
- if (!ec->hwc_window) return;
-
- state = e_hwc_window_accepted_state_get(ec->hwc_window);
- if ((state == E_HWC_WINDOW_STATE_DEVICE) || (state == E_HWC_WINDOW_STATE_VIDEO))
- e_hwc_window_present_sync(ec->hwc_window);
-
- EINA_LIST_FOREACH(ec->comp_data->sub.below_list_pending, l, subc)
- {
- if (!subc->hwc_window) continue;
- _e_hwc_window_client_subsurface_present_sync(subc);
- }
-
- EINA_LIST_FOREACH(ec->comp_data->sub.below_list, l, subc)
- {
- if (!subc->hwc_window) continue;
- _e_hwc_window_client_subsurface_present_sync(subc);
- }
-}
-
static void
_e_hwc_window_client_cb_transform_change(void *data EINA_UNUSED, E_Client *ec)
{