expo: Allow checking if a position is within a textline

For a textline it is possible to click into the edit field. Provide a
function to check whether a position is within this field.

Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
Simon Glass
2025-09-14 17:36:27 -06:00
parent 1e65b5e22e
commit 9d34fbe2e8
4 changed files with 72 additions and 3 deletions

View File

@@ -175,6 +175,12 @@ int scene_textline_send_key(struct scene *scn, struct scene_obj_textline *tline,
return 0;
}
bool scene_textline_within(const struct scene *scn,
struct scene_obj_textline *tline, int x, int y)
{
return scene_within(scn, tline->edit_id, x, y);
}
int scene_textline_render_deps(struct scene *scn,
struct scene_obj_textline *tline)
{