kimcinoo pushed a commit to branch master.
commit e4f6e93bd816a132b0112b90837d0490d6cb4adf
Author: Shinwoo Kim <[email protected]>
Date: Thu Apr 25 14:59:39 2013 +0900
[focus] update child_can_focus on parent, when an widget becomes focusable
---
src/lib/elm_widget.c | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/src/lib/elm_widget.c b/src/lib/elm_widget.c
index 8e4a0f4..1eddb6d 100644
--- a/src/lib/elm_widget.c
+++ b/src/lib/elm_widget.c
@@ -1283,6 +1283,21 @@ _elm_widget_can_focus_set(Eo *obj, void *_pd, va_list
*list)
evas_object_event_callback_add(obj, EVAS_CALLBACK_MOUSE_WHEEL,
_propagate_event,
(void
*)(long)EVAS_CALLBACK_MOUSE_WHEEL);
+
+ /* update child focusable-ness on parents, now that a
+ * focusable child got in */
+ Elm_Widget_Smart_Data *sdp = sd;
+ if (!sdp->child_can_focus)
+ {
+ sdp->child_can_focus = EINA_TRUE;
+ while (sdp->parent_obj)
+ {
+ if (sdp->child_can_focus) break;
+
+ sdp->child_can_focus = EINA_TRUE;
+ sdp = eo_data_get(sdp->parent_obj, MY_CLASS);
+ }
+ }
}
else
{
--
------------------------------------------------------------------------------
Try New Relic Now & We'll Send You this Cool Shirt
New Relic is the only SaaS-based application performance monitoring service
that delivers powerful full stack analytics. Optimize and monitor your
browser, app, & servers with just a few lines of code. Try New Relic
and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_apr