From 11e2eb4f06e9989f1dc486c60115fc2e5a9ebf62 Mon Sep 17 00:00:00 2001 From: Boram Park Date: Mon, 3 Aug 2015 10:39:16 +0900 Subject: [PATCH] remove tizen_subsurface protocol Change-Id: I1c726b6e62c2edbfee90badedcfee05e026d8d1c --- src/modules/Makefile_wl_desktop_shell.mk | 2 - src/modules/wl_desktop_shell/e_mod_main.c | 77 ---------------------- src/modules/wl_desktop_shell/tizen_subsurface.xml | 7 -- .../wl_desktop_shell/tizen_subsurface_protocol.c | 20 ------ .../tizen_subsurface_server_protocol.h | 34 ---------- 5 files changed, 140 deletions(-) delete mode 100644 src/modules/wl_desktop_shell/tizen_subsurface.xml delete mode 100644 src/modules/wl_desktop_shell/tizen_subsurface_protocol.c delete mode 100644 src/modules/wl_desktop_shell/tizen_subsurface_server_protocol.h diff --git a/src/modules/Makefile_wl_desktop_shell.mk b/src/modules/Makefile_wl_desktop_shell.mk index 6d880c7..39c5907 100644 --- a/src/modules/Makefile_wl_desktop_shell.mk +++ b/src/modules/Makefile_wl_desktop_shell.mk @@ -20,8 +20,6 @@ src_modules_wl_desktop_shell_module_la_SOURCES = \ src/modules/wl_desktop_shell/e_scaler.h \ src/modules/wl_desktop_shell/tizen_extension_server_protocol.h \ src/modules/wl_desktop_shell/tizen_extension_protocol.c \ - src/modules/wl_desktop_shell/tizen_subsurface_server_protocol.h \ - src/modules/wl_desktop_shell/tizen_subsurface_protocol.c \ src/modules/wl_desktop_shell/tizen_transient_for_server_protocol.h \ src/modules/wl_desktop_shell/tizen_transient_for_protocol.c diff --git a/src/modules/wl_desktop_shell/e_mod_main.c b/src/modules/wl_desktop_shell/e_mod_main.c index 2a0c100..31ff5f7 100644 --- a/src/modules/wl_desktop_shell/e_mod_main.c +++ b/src/modules/wl_desktop_shell/e_mod_main.c @@ -5,7 +5,6 @@ #include #include "e_scaler.h" #include "tizen_extension_server_protocol.h" -#include "tizen_subsurface_server_protocol.h" #include "tizen_transient_for_server_protocol.h" #define XDG_SERVER_VERSION 4 @@ -1710,71 +1709,6 @@ _e_tz_transient_for_cb_bind(struct wl_client *client, void *data, uint32_t versi wl_resource_set_implementation(res, &_e_tz_transient_for_interface, cdata, NULL); } -static void -_e_tz_subsurface_cb_place_below_parent(struct wl_client *client, struct wl_resource *resource, struct wl_resource *subsurface) -{ - E_Client *ec; - E_Client *epc; - E_Comp_Wl_Subsurf_Data *sdata; - - /* try to get the client from resource data */ - if (!(ec = wl_resource_get_user_data(subsurface))) - { - wl_resource_post_error(resource, WL_DISPLAY_ERROR_INVALID_OBJECT, - "Invalid subsurface"); - return; - } - - sdata = ec->comp_data->sub.data; - if (!sdata) - { - wl_resource_post_error(resource, WL_DISPLAY_ERROR_INVALID_OBJECT, - "Not subsurface"); - return; - } - - epc = sdata->parent; - EINA_SAFETY_ON_NULL_RETURN(epc); - - /* check if a subsurface has already placed below a parent */ - if (eina_list_data_find(epc->comp_data->sub.below_list, ec)) return; - - epc->comp_data->sub.list = eina_list_remove(epc->comp_data->sub.list, ec); - epc->comp_data->sub.list_pending = eina_list_remove(epc->comp_data->sub.list_pending, ec); - epc->comp_data->sub.below_list_pending = eina_list_append(epc->comp_data->sub.below_list_pending, ec); - epc->comp_data->sub.list_changed = EINA_TRUE; -} - -static const struct tizen_subsurface_interface _e_tz_subsurface_interface = -{ - _e_tz_subsurface_cb_place_below_parent, -}; - -static void -_e_tz_subsurface_cb_bind(struct wl_client *client, void *data, uint32_t version, uint32_t id) -{ - E_Comp_Data *cdata; - struct wl_resource *res; - - if (!(cdata = data)) - { - wl_client_post_no_memory(client); - return; - } - - if (!(res = wl_resource_create(client, - &tizen_subsurface_interface, - MIN(version, 1), - id))) - { - ERR("Could not create tizen_subsurface resource: %m"); - wl_client_post_no_memory(client); - return; - } - - wl_resource_set_implementation(res, &_e_tz_subsurface_interface, cdata, NULL); -} - EAPI E_Module_Api e_modapi = { E_MODULE_API_VERSION, "Wl_Desktop_Shell" }; EAPI void * @@ -1831,17 +1765,6 @@ e_modapi_init(E_Module *m) return NULL; } - /* try to create global tizen subsurface interface */ - if (!wl_global_create(cdata->wl.disp, - &tizen_subsurface_interface, - 1, - cdata, - _e_tz_subsurface_cb_bind)) - { - ERR("Could not create tizen_surface_extension to wayland globals: %m"); - return NULL; - } - if (!wl_global_create(cdata->wl.disp, &tizen_surface_interface, 1, diff --git a/src/modules/wl_desktop_shell/tizen_subsurface.xml b/src/modules/wl_desktop_shell/tizen_subsurface.xml deleted file mode 100644 index 16bd5f2..0000000 --- a/src/modules/wl_desktop_shell/tizen_subsurface.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/src/modules/wl_desktop_shell/tizen_subsurface_protocol.c b/src/modules/wl_desktop_shell/tizen_subsurface_protocol.c deleted file mode 100644 index b3950da..0000000 --- a/src/modules/wl_desktop_shell/tizen_subsurface_protocol.c +++ /dev/null @@ -1,20 +0,0 @@ -#include -#include -#include "wayland-util.h" - -extern const struct wl_interface wl_subsurface_interface; - -static const struct wl_interface *types[] = { - &wl_subsurface_interface, -}; - -static const struct wl_message tizen_subsurface_requests[] = { - { "place_below_parent", "o", types + 0 }, -}; - -WL_EXPORT const struct wl_interface tizen_subsurface_interface = { - "tizen_subsurface", 1, - 1, tizen_subsurface_requests, - 0, NULL, -}; - diff --git a/src/modules/wl_desktop_shell/tizen_subsurface_server_protocol.h b/src/modules/wl_desktop_shell/tizen_subsurface_server_protocol.h deleted file mode 100644 index c283c84..0000000 --- a/src/modules/wl_desktop_shell/tizen_subsurface_server_protocol.h +++ /dev/null @@ -1,34 +0,0 @@ -#ifndef TIZEN_SUBSURFACE_SERVER_PROTOCOL_H -#define TIZEN_SUBSURFACE_SERVER_PROTOCOL_H - -#ifdef __cplusplus -extern "C" { -#endif - -#include -#include -#include "wayland-server.h" - -struct wl_client; -struct wl_resource; - -struct tizen_subsurface; - -extern const struct wl_interface tizen_subsurface_interface; - -struct tizen_subsurface_interface { - /** - * place_below_parent - (none) - * @subsurface: (none) - */ - void (*place_below_parent)(struct wl_client *client, - struct wl_resource *resource, - struct wl_resource *subsurface); -}; - - -#ifdef __cplusplus -} -#endif - -#endif -- 2.7.4