e_policy: send iconify state change event when ec vis turn on and didn't send event. 29/248929/5
authorJunseok, Kim <juns.kim@samsung.com>
Thu, 3 Dec 2020 06:12:04 +0000 (15:12 +0900)
committerDoyoun Kang <doyoun.kang@samsung.com>
Thu, 3 Dec 2020 10:56:05 +0000 (10:56 +0000)
Added last_sent_type for store latest iconify_state_change event.
and send iconify_state_change event when ec turn to visibility on and didn't send the event.

Change-Id: I74c33b4ade57c095c2287273d54a4ae1237666c2
Signed-off-by: Junseok, Kim <juns.kim@samsung.com>
src/bin/e_client.h
src/bin/e_policy.c
src/bin/e_policy_wl.c

index 5406568b5eed14a82041c532bb927a33aca888e4..e636838461a5f18cf56d8e73952e8871c8e931af 100644 (file)
@@ -886,6 +886,7 @@ struct E_Client
       unsigned char skip_by_remote : 1;    // skip iconify by remote surface client
       unsigned char deiconify_update : 1;  // wait client render if deiconify_update is 1
       unsigned char buffer_flush : 1;      // 0: no flush, 1: flush buffer when iconify
+      unsigned char last_sent_iconic : 1;  // 0: uniconify, 1: iconify
    } exp_iconify;
 
    struct
index 424bd4ae04e301485172a39f91688389a902ea62..7969f1270222f929b1d22a39ec667e1e0cdc71bc 100644 (file)
@@ -884,6 +884,8 @@ _e_policy_cb_hook_client_visibility(void *d EINA_UNUSED, E_Client *ec)
         if (ec->visibility.obscured == E_VISIBILITY_UNOBSCURED)
           {
              e_policy_client_uniconify_by_visibility(ec);
+             if ((ec->iconic == 0) && (ec->exp_iconify.last_sent_iconic != 0))
+               e_policy_wl_iconify_state_change_send(ec, 0);
              if (ec->visibility.last_sent_type != E_VISIBILITY_PRE_UNOBSCURED)
                {
                   ELOGF("POL_VIS", "SEND pre-unobscured visibility event", ec);
index 3f752b3c65dae1bc4698af5ea2126d34874d9671..842e4bae75030c94f7017d44a8bc42be1b912d06 100644 (file)
@@ -1172,6 +1172,7 @@ e_policy_wl_iconify_state_change_send(E_Client *ec, int iconic)
                 "SEND     |iconic:%d  |argb:%d       |sur:%p",
                 ec,
                 iconic, ec->argb, psurf->surf);
+          ec->exp_iconify.last_sent_iconic = iconic;
           break;
        }
    eina_iterator_free(it);