rotation: check ec's rotating state before sending E_EVENT_CLIENT_ROTATION_CHANGE_BEG... 20/125220/1
authorDoyoun Kang <doyoun.kang@samsung.com>
Fri, 14 Apr 2017 07:22:22 +0000 (16:22 +0900)
committerDoyoun Kang <doyoun.kang@samsung.com>
Fri, 14 Apr 2017 07:22:34 +0000 (16:22 +0900)
There was a bug that the E_EVENT_CLIENT_ROTATION_CHANGE_BEGIN event is sent twice, but
E_EVENT_CLIENT_ROTATION_CHANGE_CANCEL or E_EVENT_CLIENT_ROTATION_CHANGE_END is sent just once.

Change-Id: I897770824c818a57ae4bf7703d98ea6987d47d82

src/rotation/e_mod_rotation_wl.c

index 640f996..924e044 100644 (file)
@@ -1709,7 +1709,10 @@ e_client_rotation_set(E_Client *ec, int rotation)
      }
    eina_list_free(list);
 
-   _e_client_event_client_rotation_change_begin_send(ec);
+   if (!e_client_rotation_is_progress(ec))
+     {
+        _e_client_event_client_rotation_change_begin_send(ec);
+     }
 
    ec->e.state.rot.pending_change_request = 0;
    ec->e.state.rot.ang.next = rotation;