Drag & Drop: add overlapping feature

Desktop / Enlightenment / Elementary - Daniel Zaoui [samsung.com] - 21 October 2013 11:04 UTC

This feature is essential if two overlapping widgets can receive drop information. Until now, if two widgets (e.g background and button) were added as drop targets, pointing to common coordinates would have given priority to the first inserted as drop target. Now, it will determine which widget is supposed to receive this drop target by using the same mechanism as used for mouse move, i.e by walking on the objects tree whose pointer passes through.

A test has been added (Overlapping DnD) to show how this feature can be used. You can drop in bg, box and button.

65f6847 Drag & Drop: add overlapping feature.
src/bin/test.c | 2 +
src/bin/test_dnd.c | 153 +++++++++++++++++++++++++++++++++++++++++++++++++---
src/lib/elm_cnp.c | 96 +++++++++++++++++++++------------
3 files changed, 212 insertions(+), 39 deletions(-)

Upstream: git.enlightenment.org


  • Share