quickpanel: rename scroll_state_* to scrollable_state_* 82/226082/3 accepted/tizen/unified/20200228.123718 submit/tizen/20200227.111751
authorJunseok, Kim <juns.kim@samsung.com>
Wed, 26 Feb 2020 12:58:41 +0000 (21:58 +0900)
committerJunseok, Kim <juns.kim@samsung.com>
Thu, 27 Feb 2020 10:30:33 +0000 (19:30 +0900)
Change-Id: I50d9fcf5efde96f214d29293926ecf19185cbea1

src/bin/e_policy_wl.c
src/bin/services/e_service_quickpanel.c
src/bin/services/e_service_quickpanel.h

index d683ee5cadbcec97f2ecfa9265016e0209a730f9..bab4a6942d6b05566b04aa3339c5700e21a0b3f2 100644 (file)
@@ -4885,12 +4885,12 @@ _tzsh_qp_iface_cb_type_set(struct wl_client *client EINA_UNUSED, struct wl_resou
 }
 
 static void
-_tzsh_qp_iface_cb_scroll_state_set(struct wl_client *client EINA_UNUSED, struct wl_resource *res_tzsh_qp, int32_t state)
+_tzsh_qp_iface_cb_scrollable_state_set(struct wl_client *client EINA_UNUSED, struct wl_resource *res_tzsh_qp, int32_t state)
 {
    E_Policy_Wl_Tzsh_Client *tzsh_client;
    E_Client *ec;
 
-   ELOGF("TZ_QUICKPANEL", "Request to Set scroll state to %d", NULL, state);
+   ELOGF("TZ_QUICKPANEL", "Request to Set scrollable state to %d", NULL, state);
 
    tzsh_client = wl_resource_get_user_data(res_tzsh_qp);
    EINA_SAFETY_ON_NULL_RETURN(tzsh_client);
@@ -4905,11 +4905,11 @@ _tzsh_qp_iface_cb_scroll_state_set(struct wl_client *client EINA_UNUSED, struct
      return;
 
    if (state == TWS_QUICKPANEL_STATE_VALUE_SCROLLABLE_UNSET)
-     e_qp_client_scroll_state_set(ec, tzsh_client->qp_type, E_QUICKPANEL_CLIENT_SCROLL_STATE_UNSET);
+     e_qp_client_scrollable_state_set(ec, tzsh_client->qp_type, E_QUICKPANEL_CLIENT_SCROLL_STATE_UNSET);
    else if (state == TWS_QUICKPANEL_STATE_VALUE_SCROLLABLE_SET)
-     e_qp_client_scroll_state_set(ec, tzsh_client->qp_type, E_QUICKPANEL_CLIENT_SCROLL_STATE_SET);
-   else if (state == TWS_QUICKPANEL_STATE_VALUE_SCROLLABLE_FOLLOW)
-     e_qp_client_scroll_state_set(ec, tzsh_client->qp_type, E_QUICKPANEL_CLIENT_SCROLL_STATE_FOLLOW);
+     e_qp_client_scrollable_state_set(ec, tzsh_client->qp_type, E_QUICKPANEL_CLIENT_SCROLL_STATE_SET);
+   else if (state == TWS_QUICKPANEL_STATE_VALUE_SCROLLABLE_RETAIN)
+     e_qp_client_scrollable_state_set(ec, tzsh_client->qp_type, E_QUICKPANEL_CLIENT_SCROLL_STATE_RETAIN);
 
 }
 
@@ -4922,7 +4922,7 @@ static const struct tws_quickpanel_interface _tzsh_qp_iface =
    _tzsh_qp_iface_cb_disable,
    _tzsh_qp_iface_cb_state_get,
    _tzsh_qp_iface_cb_type_set,
-   _tzsh_qp_iface_cb_scroll_state_set
+   _tzsh_qp_iface_cb_scrollable_state_set
 };
 
 static void
index 4fe8cb4c70bbabd8cc023b7a49e4d04fdbe65e3e..83c444bec8d4b64259620419a698d5c47901c665 100644 (file)
@@ -169,8 +169,8 @@ Eina_List *qp_clients = NULL; /* list of E_QP_Client */
 static void          _e_qp_srv_effect_update(E_Policy_Quickpanel *qp, int x, int y);
 static E_QP_Client * _e_qp_client_ec_get(E_Client *ec, E_Quickpanel_Type type);
 static Eina_Bool     _e_qp_client_scrollable_update(E_Policy_Quickpanel *qp);
-static Eina_Bool     _e_qp_client_scroll_state_set(E_Client *ec, E_Quickpanel_Type type, int state);
-static int           _e_qp_client_scroll_state_get(E_Client *ec, E_Quickpanel_Type type);
+static Eina_Bool     _e_qp_client_scrollable_state_set(E_Client *ec, E_Quickpanel_Type type, int state);
+static int           _e_qp_client_scrollable_state_get(E_Client *ec, E_Quickpanel_Type type);
 
 static void          _quickpanel_client_evas_cb_show(void *data, Evas *evas, Evas_Object *obj, void *event);
 static void          _quickpanel_client_evas_cb_hide(void *data, Evas *evas, Evas_Object *obj, void *event);
@@ -1000,7 +1000,7 @@ _e_qp_check_scrollable(E_Policy_Quickpanel *qp)
 
         qp_client = _e_qp_client_ec_get(ec, (E_Quickpanel_Type)qp->type);
         if (!qp_client) continue;
-        if (qp_client->hint.scrollable == E_QUICKPANEL_CLIENT_SCROLL_STATE_FOLLOW)
+        if (qp_client->hint.scrollable == E_QUICKPANEL_CLIENT_SCROLL_STATE_RETAIN)
           continue;
 
         if (qp_client->hint.scrollable == E_QUICKPANEL_CLIENT_SCROLL_STATE_SET)
@@ -1117,7 +1117,7 @@ _region_obj_cb_gesture_start(void *data, Evas_Object *handler, int nfingers, int
              ELOGF("QUICKPANEL", "Scroll locked by current client", qp->below);
              return;
           }
-        else if (qp_client->hint.scrollable == E_QUICKPANEL_CLIENT_SCROLL_STATE_FOLLOW)
+        else if (qp_client->hint.scrollable == E_QUICKPANEL_CLIENT_SCROLL_STATE_RETAIN)
           {
              ELOGF("QUICKPANEL", "Scroll follow by previous client", qp->below);
              scrollable = _e_qp_check_scrollable(qp);
@@ -2438,7 +2438,7 @@ EINTERN Eina_Bool
 e_qp_client_scrollable_set(E_Client *ec, E_Quickpanel_Type type, Eina_Bool set)
 {
    /*
-      USE e_qp_client_scroll_state_set() function instead of this function.
+      USE e_qp_client_scrollable_state_set() function instead of this function.
       This will be DEPRECATED.
    */
    Eina_Bool ret;
@@ -2447,9 +2447,9 @@ e_qp_client_scrollable_set(E_Client *ec, E_Quickpanel_Type type, Eina_Bool set)
    BACKEND_FUNC_CALL_RET(qp_client_scrollable_set, ec, type, set);
 
    if (set)
-     ret = _e_qp_client_scroll_state_set(ec, type, E_QUICKPANEL_CLIENT_SCROLL_STATE_SET);
+     ret = _e_qp_client_scrollable_state_set(ec, type, E_QUICKPANEL_CLIENT_SCROLL_STATE_SET);
    else
-     ret = _e_qp_client_scroll_state_set(ec, type, E_QUICKPANEL_CLIENT_SCROLL_STATE_UNSET);
+     ret = _e_qp_client_scrollable_state_set(ec, type, E_QUICKPANEL_CLIENT_SCROLL_STATE_UNSET);
 
    return ret;
 }
@@ -2458,22 +2458,22 @@ EINTERN Eina_Bool
 e_qp_client_scrollable_get(E_Client *ec, E_Quickpanel_Type type)
 {
    /*
-      USE e_qp_client_scroll_state_get() function instead of this function.
+      USE e_qp_client_scrollable_state_get() function instead of this function.
       This will be DEPRECATED.
    */
-   int scroll_state;
+   int scrollable_state;
 
    BACKEND_FUNC_CALL_RET(qp_client_scrollable_get, ec, type);
 
-   scroll_state = _e_qp_client_scroll_state_get(ec, type);
-   if (scroll_state == E_QUICKPANEL_CLIENT_SCROLL_STATE_UNSET)
+   scrollable_state = _e_qp_client_scrollable_state_get(ec, type);
+   if (scrollable_state == E_QUICKPANEL_CLIENT_SCROLL_STATE_UNSET)
      return EINA_FALSE;
    else
      return EINA_TRUE;
 }
 
 static Eina_Bool
-_e_qp_client_scroll_state_set(E_Client *ec, E_Quickpanel_Type type, int state)
+_e_qp_client_scrollable_state_set(E_Client *ec, E_Quickpanel_Type type, int state)
 {
    E_Policy_Quickpanel *qp;
    E_QP_Client *qp_client;
@@ -2495,7 +2495,7 @@ _e_qp_client_scroll_state_set(E_Client *ec, E_Quickpanel_Type type, int state)
 }
 
 static int
-_e_qp_client_scroll_state_get(E_Client *ec, E_Quickpanel_Type type)
+_e_qp_client_scrollable_state_get(E_Client *ec, E_Quickpanel_Type type)
 {
    E_QP_Client *qp_client;
 
@@ -2506,20 +2506,20 @@ _e_qp_client_scroll_state_get(E_Client *ec, E_Quickpanel_Type type)
 }
 
 EINTERN Eina_Bool
-e_qp_client_scroll_state_set(E_Client *ec, E_Quickpanel_Type type, int state)
+e_qp_client_scrollable_state_set(E_Client *ec, E_Quickpanel_Type type, int state)
 {
-   ELOGF("QUICKPANEL", "Request to Set scroll state of Quickpanel(type:%d) to %d", ec, type, state);
-   BACKEND_FUNC_CALL_RET(qp_client_scroll_state_set, ec, type, state);
+   ELOGF("QUICKPANEL", "Request to Set scrollable state of Quickpanel(type:%d) to %d", ec, type, state);
+   BACKEND_FUNC_CALL_RET(qp_client_scrollable_state_set, ec, type, state);
 
-   return _e_qp_client_scroll_state_set(ec, type, state);
+   return _e_qp_client_scrollable_state_set(ec, type, state);
 }
 
 EINTERN int
-e_qp_client_scroll_state_get(E_Client *ec, E_Quickpanel_Type type)
+e_qp_client_scrollable_state_get(E_Client *ec, E_Quickpanel_Type type)
 {
    E_QP_Client *qp_client;
 
-   BACKEND_FUNC_CALL_RET(qp_client_scroll_state_get, ec, type);
+   BACKEND_FUNC_CALL_RET(qp_client_scrollable_state_get, ec, type);
 
    qp_client = _e_qp_client_ec_get(ec, type);
    EINA_SAFETY_ON_NULL_RETURN_VAL(qp_client, EINA_FALSE);
@@ -2553,8 +2553,8 @@ e_service_quickpanel_module_func_set(E_QP_Mgr_Funcs *fp)
    qp_mgr_funcs->qp_client_hide = fp->qp_client_hide;
    qp_mgr_funcs->qp_client_scrollable_set = fp->qp_client_scrollable_set;
    qp_mgr_funcs->qp_client_scrollable_get = fp->qp_client_scrollable_get;
-   qp_mgr_funcs->qp_client_scroll_state_set = fp->qp_client_scroll_state_set;
-   qp_mgr_funcs->qp_client_scroll_state_get = fp->qp_client_scroll_state_get;
+   qp_mgr_funcs->qp_client_scrollable_state_set = fp->qp_client_scrollable_state_set;
+   qp_mgr_funcs->qp_client_scrollable_state_get = fp->qp_client_scrollable_state_get;
    return EINA_TRUE;
 }
 
index 858c58a5104bb05cae13a88b5e58c2e1caa1ab6e..9665503893cbe7a3942a6566a3a50ac129c31f9a 100644 (file)
@@ -17,7 +17,7 @@ typedef enum
 {
    E_QUICKPANEL_CLIENT_SCROLL_STATE_UNSET  = 0,  /* TWS_QUICKPANEL_STATE_VALUE_SCROLLABLE_UNSET */
    E_QUICKPANEL_CLIENT_SCROLL_STATE_SET    = 1,  /* TWS_QUICKPANEL_STATE_VALUE_SCROLLABLE_SET */
-   E_QUICKPANEL_CLIENT_SCROLL_STATE_FOLLOW = 2,  /* TWS_QUICKPANEL_STATE_VALUE_SCROLLABLE_FOLLOW */
+   E_QUICKPANEL_CLIENT_SCROLL_STATE_RETAIN = 2,  /* TWS_QUICKPANEL_STATE_VALUE_SCROLLABLE_RETAIN */
 } E_Quickpanel_Client_Scroll_State;
 
 struct _E_QP_Mgr_Funcs
@@ -40,8 +40,8 @@ struct _E_QP_Mgr_Funcs
    void      (*qp_client_hide)(E_Client *ec, E_Quickpanel_Type type);
    Eina_Bool (*qp_client_scrollable_set)(E_Client *ec, E_Quickpanel_Type type, Eina_Bool set);
    Eina_Bool (*qp_client_scrollable_get)(E_Client *ec, E_Quickpanel_Type type);
-   Eina_Bool (*qp_client_scroll_state_set)(E_Client *ec, E_Quickpanel_Type type, int state);
-   int       (*qp_client_scroll_state_get)(E_Client *ec, E_Quickpanel_Type type);
+   Eina_Bool (*qp_client_scrollable_state_set)(E_Client *ec, E_Quickpanel_Type type, int state);
+   int       (*qp_client_scrollable_state_get)(E_Client *ec, E_Quickpanel_Type type);
 };
 
 E_API Eina_Bool   e_service_quickpanel_module_func_set(E_QP_Mgr_Funcs *fp);
@@ -67,7 +67,7 @@ EINTERN void      e_qp_client_show(E_Client *ec, E_Quickpanel_Type type);
 EINTERN void      e_qp_client_hide(E_Client *ec, E_Quickpanel_Type type);
 EINTERN Eina_Bool e_qp_client_scrollable_set(E_Client *ec, E_Quickpanel_Type type, Eina_Bool set);
 EINTERN Eina_Bool e_qp_client_scrollable_get(E_Client *ec, E_Quickpanel_Type type);
-EINTERN Eina_Bool e_qp_client_scroll_state_set(E_Client *ec, E_Quickpanel_Type type, int state);
-EINTERN int       e_qp_client_scroll_state_get(E_Client *ec, E_Quickpanel_Type type);
+EINTERN Eina_Bool e_qp_client_scrollable_state_set(E_Client *ec, E_Quickpanel_Type type, int state);
+EINTERN int       e_qp_client_scrollable_state_get(E_Client *ec, E_Quickpanel_Type type);
 
 #endif