summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCedric Bail <cedric.bail@free.fr>2019-10-31 13:20:45 -0400
committerMike Blumenkrantz <zmike@samsung.com>2019-10-31 13:29:56 -0400
commit21f07b9fa980ffa181a0e88865236fc0c5bac9e7 (patch)
tree24f2c9c7b52aacb0df610761be18f4f04c3a8168
parent3fd669376470e03ec7ebe33e0040bc186c7ce913 (diff)
evas: deprecate evas_device_parent_set.
Summary: It is unlikely that the code was working before and it was a bad idea anyway. There is no user of this API in EFL. Depends on D10490 Reviewers: zmike, raster, bu5hm4n, Hermet Reviewed By: zmike Subscribers: #reviewers, #committers Tags: #efl Maniphest Tasks: T8321 Differential Revision: https://phab.enlightenment.org/D10491
-rw-r--r--src/lib/evas/Evas_Common.h2
-rw-r--r--src/lib/evas/canvas/evas_device.c17
2 files changed, 3 insertions, 16 deletions
diff --git a/src/lib/evas/Evas_Common.h b/src/lib/evas/Evas_Common.h
index f68f544dd3..632260fbe0 100644
--- a/src/lib/evas/Evas_Common.h
+++ b/src/lib/evas/Evas_Common.h
@@ -1159,7 +1159,7 @@ EAPI const char *evas_device_description_get(const Evas_Device *dev);
1159 * 1159 *
1160 * @since 1.8 1160 * @since 1.8
1161 */ 1161 */
1162EAPI void evas_device_parent_set(Evas_Device *dev, Evas_Device *parent); 1162EAPI void evas_device_parent_set(Evas_Device *dev, Evas_Device *parent) EINA_DEPRECATED;
1163 1163
1164/** 1164/**
1165 * Get the parent of a device 1165 * Get the parent of a device
diff --git a/src/lib/evas/canvas/evas_device.c b/src/lib/evas/canvas/evas_device.c
index af95619044..1652e79100 100644
--- a/src/lib/evas/canvas/evas_device.c
+++ b/src/lib/evas/canvas/evas_device.c
@@ -330,25 +330,12 @@ evas_device_description_get(const Evas_Device *dev)
330} 330}
331 331
332EAPI void 332EAPI void
333evas_device_parent_set(Evas_Device *dev, Evas_Device *parent) 333evas_device_parent_set(Evas_Device *dev EINA_UNUSED, Evas_Device *parent EINA_UNUSED)
334{ 334{
335 // Note: This function should be deprecated. parent_set doesn't make sense 335 // Note: This function should be deprecated. parent_set doesn't make sense
336 // unless the parent is a seat device. Parent shouldn't be changed after 336 // unless the parent is a seat device. Parent shouldn't be changed after
337 // creation. 337 // creation.
338 338 ERR("It is not advised and possible anymore to changed the parent of an Evas_Device.");
339 SAFETY_CHECK(dev, EFL_INPUT_DEVICE_CLASS);
340
341 if (parent)
342 {
343 SAFETY_CHECK(parent, EFL_INPUT_DEVICE_CLASS);
344 }
345 else if (efl_parent_get(dev))
346 {
347 efl_ref(dev);
348 }
349
350 efl_parent_set(dev, parent);
351 evas_event_callback_call(efl_input_device_evas_get(dev), EVAS_CALLBACK_DEVICE_CHANGED, dev);
352} 339}
353 340
354EAPI const Evas_Device * 341EAPI const Evas_Device *