woohyun pushed a commit to branch master.
commit fe4369143e99d1eac48ba4d098183c27a9d7b832
Author: WooHyun Jung <[email protected]>
Date: Thu May 30 15:24:32 2013 +0900
elementary/elc_ctxpopup : When content is not internal elm_list, focus
direction should be controlled inside ctxpopup.
---
src/lib/elc_ctxpopup.c | 33 +++++++++++++++++++++++++++++++++
1 file changed, 33 insertions(+)
diff --git a/src/lib/elc_ctxpopup.c b/src/lib/elc_ctxpopup.c
index 0e722ae..2a6a815 100644
--- a/src/lib/elc_ctxpopup.c
+++ b/src/lib/elc_ctxpopup.c
@@ -134,6 +134,39 @@ _elm_ctxpopup_smart_event(Eo *obj, void *_pd, va_list
*list)
return;
}
+ if (((!strcmp(ev->keyname, "Left")) ||
+ (!strcmp(ev->keyname, "KP_Left")) ||
+ (!strcmp(ev->keyname, "Right")) ||
+ (!strcmp(ev->keyname, "KP_Right")) ||
+ (!strcmp(ev->keyname, "Up")) ||
+ (!strcmp(ev->keyname, "KP_Up")) ||
+ (!strcmp(ev->keyname, "Down")) ||
+ (!strcmp(ev->keyname, "KP_Down"))) && (!ev->string))
+ {
+ if (sd->box)
+ {
+ double degree = 0.0;
+
+ if ((!strcmp(ev->keyname, "Left")) ||
+ (!strcmp(ev->keyname, "KP_Left")))
+ degree = 270.0;
+ else if ((!strcmp(ev->keyname, "Right")) ||
+ (!strcmp(ev->keyname, "KP_Right")))
+ degree = 90.0;
+ else if ((!strcmp(ev->keyname, "Up")) ||
+ (!strcmp(ev->keyname, "KP_Up")))
+ degree = 0.0;
+ else if ((!strcmp(ev->keyname, "Down")) ||
+ (!strcmp(ev->keyname, "KP_Down")))
+ degree = 180.0;
+
+ elm_widget_focus_direction_go(obj, degree);
+ ev->event_flags |= EVAS_EVENT_FLAG_ON_HOLD;
+ if (ret) *ret = EINA_TRUE;
+ return;
+ }
+ }
+
if (strcmp(ev->keyname, "Escape")) return;
evas_object_hide(obj);
--
------------------------------------------------------------------------------
Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET
Get 100% visibility into your production application - at no cost.
Code-level diagnostics for performance bottlenecks with <2% overhead
Download for free and get started troubleshooting in minutes.
http://p.sf.net/sfu/appdyn_d2d_ap1