summaryrefslogtreecommitdiff
path: root/src/lib/ecore_wl2/ecore_wl2.c
diff options
context:
space:
mode:
authorDerek Foreman <derekf@osg.samsung.com>2018-01-26 13:00:35 -0600
committerDerek Foreman <derekf@osg.samsung.com>2018-01-26 15:54:00 -0600
commit03671c9c2009e9cda7f750d28417e2c8e1f78fa8 (patch)
tree291eb34f931e60ac40d526e537a1b5a556050451 /src/lib/ecore_wl2/ecore_wl2.c
parent83f8db157e1b47fc3398ccd6f51c421762f9c227 (diff)
ecore_wl2: Add a way to register new surface managers
And use it for the existing dmabuf surface manager.
Diffstat (limited to '')
-rw-r--r--src/lib/ecore_wl2/ecore_wl2.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/lib/ecore_wl2/ecore_wl2.c b/src/lib/ecore_wl2/ecore_wl2.c
index c309a92b37..7a1bbee649 100644
--- a/src/lib/ecore_wl2/ecore_wl2.c
+++ b/src/lib/ecore_wl2/ecore_wl2.c
@@ -57,6 +57,12 @@ EAPI int ECORE_WL2_EVENT_WINDOW_ICONIFY_STATE_CHANGE = 0;
57EAPI int _ecore_wl2_event_window_www = -1; 57EAPI int _ecore_wl2_event_window_www = -1;
58EAPI int _ecore_wl2_event_window_www_drag = -1; 58EAPI int _ecore_wl2_event_window_www_drag = -1;
59 59
60static Eina_Bool
61_ecore_wl2_surface_modules_init(void)
62{
63 return ecore_wl2_surface_manager_dmabuf_add();
64}
65
60/* public API functions */ 66/* public API functions */
61EAPI int 67EAPI int
62ecore_wl2_init(void) 68ecore_wl2_init(void)
@@ -89,6 +95,12 @@ ecore_wl2_init(void)
89 goto ecore_event_err; 95 goto ecore_event_err;
90 } 96 }
91 97
98 if (!_ecore_wl2_surface_modules_init())
99 {
100 ERR("Could not load surface modules");
101 goto module_load_err;
102 }
103
92 /* handle creating new Ecore_Wl2 event types */ 104 /* handle creating new Ecore_Wl2 event types */
93 ECORE_WL2_EVENT_CONNECT = ecore_event_type_new(); 105 ECORE_WL2_EVENT_CONNECT = ecore_event_type_new();
94 ECORE_WL2_EVENT_DISCONNECT = ecore_event_type_new(); 106 ECORE_WL2_EVENT_DISCONNECT = ecore_event_type_new();
@@ -139,6 +151,9 @@ ecore_wl2_init(void)
139 151
140 return _ecore_wl2_init_count; 152 return _ecore_wl2_init_count;
141 153
154module_load_err:
155 ecore_event_shutdown();
156
142ecore_event_err: 157ecore_event_err:
143 ecore_shutdown(); 158 ecore_shutdown();
144 159