subsurface: fix not being able to update stack by place_below_parent. 91/246491/2
authorSeunghun Lee <shiin.lee@samsung.com>
Fri, 30 Oct 2020 03:08:10 +0000 (12:08 +0900)
committerSeunghun Lee <shiin.lee@samsung.com>
Fri, 30 Oct 2020 04:17:23 +0000 (13:17 +0900)
This problem was caused by the following patch I made for the reason that
described in the commit message.

===
commit 3d028b1c348ab53170b4f6e70ebe0794de14ff8d
Author: Seunghun Lee <shiin.lee@samsung.com>
Date:   Thu Oct 22 13:41:18 2020 +0900

    subsurface: Do not update stacking order of entire sub-surface tree.
===

The stacking order of sub-surface should be actually updated when state
of its immediate parent is applied according to the wl_subsurface
description.

However, 'tizen_policy.subsurface_place_below_parent' seems not to be
designed like that. So, just let 'tizen_policy.subsurface_place_below_parent'
update the stacking order immediately.
Otherwise I think this protocol can't support backward comatibility.
Clients of wayland server must be assuming that changing stacking order by
this protocol will be applied regardless of state of its parent.

Change-Id: I11a7644d16431f612a5674851a40964a48d97bbf

src/bin/e_policy_wl.c

index 372a6a9df6e997fc3a39c0bac05dd1d10847284b..7bb37c7547bcbfcbe876d6f2cf8c5337ec0b9b72 100644 (file)
@@ -2067,6 +2067,16 @@ _tzpol_iface_cb_subsurf_place_below_parent(struct wl_client *client EINA_UNUSED,
    epc_cdata->sub.list_pending = eina_list_remove(epc_cdata->sub.list_pending, ec);
    epc_cdata->sub.below_list = eina_list_append(epc_cdata->sub.below_list, ec);
    epc_cdata->sub.list_changed = EINA_TRUE;
+
+   /* NOTE
+    * The stacking order of sub-surface should be actually updated when state
+    * of its immediate parent is applied according to the wl_subsurface
+    * description. However, let this API associated with
+    * tizen_policy.subsurface_place_below_parent be excepted. Otherwise this
+    * API can't support backward comatibility. Clients of wayland server
+    * have been assuming that changing stacking order by this API will be
+    * applied regardless of state of its parent. */
+   e_comp_wl_subsurface_order_commit(epc);
 }
 
 static void