Canvas layout: fix part text cursor geometry port

Forgot to consider the edje object's offset when porting the code
to efl_part (see 98dad1a52b).
This fixes a few bugs, one of which is region_show for the scrollable
mode.
This commit is contained in:
Daniel Hirt 2017-06-21 10:47:08 +03:00
parent 4ca83755ed
commit 40e97c6589
1 changed files with 6 additions and 1 deletions

View File

@ -171,7 +171,12 @@ _efl_canvas_layout_internal_text_efl_text_cursor_cursor_geometry_get(Eo *obj,
Evas_Coord *cw2 EINA_UNUSED, Evas_Coord *ch2 EINA_UNUSED)
{
PROXY_DATA_GET(obj, pd);
_edje_entry_cursor_geometry_get(pd->rp, cx, cy, cw, ch, NULL);
if (pd->rp->part->entry_mode > EDJE_ENTRY_EDIT_MODE_NONE)
{
_edje_entry_cursor_geometry_get(pd->rp, cx, cy, cw, ch, NULL);
if (cx) *cx -= pd->ed->x;
if (cy) *cy -= pd->ed->y;
}
RETURN_VAL(EINA_FALSE);
}