From: ChunEon Park Date: Fri, 29 Mar 2013 06:39:05 +0000 (+0900) Subject: Log: X-Git-Tag: accepted/tizen/20130607.213307~97 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7b8696f2e6d69c3bdc5928fc3d361e667a0c20a6;p=profile%2Fmobile%2Felementary.git Log: elementary/glview - support "language,changed" callback Author: hermet Date: 2013-02-11 22:33:19 -0800 (Mon, 11 Feb 2013) New Revision: 83839 Trac: http://trac.enlightenment.org/e/changeset/83839 Change-Id: Ied03fc12adb6d4ca43c08a6a7aae4efdea359e38 --- diff --git a/src/lib/elm_glview.c b/src/lib/elm_glview.c index db12c9c..ec41855 100644 --- a/src/lib/elm_glview.c +++ b/src/lib/elm_glview.c @@ -6,11 +6,13 @@ EAPI const char ELM_GLVIEW_SMART_NAME[] = "elm_glview"; static const char SIG_FOCUSED[] = "focused"; static const char SIG_UNFOCUSED[] = "unfocused"; +static const char SIG_LANG_CHANGED[] = "language,changed"; /* smart callbacks coming from elm glview objects: */ static const Evas_Smart_Cb_Description _smart_callbacks[] = { {SIG_FOCUSED, ""}, {SIG_UNFOCUSED, ""}, + {SIG_LANG_CHANGED, ""}, {NULL, NULL} }; @@ -19,6 +21,13 @@ EVAS_SMART_SUBCLASS_NEW Elm_Widget_Smart_Class, elm_widget_smart_class_get, _smart_callbacks); static Eina_Bool +_elm_glview_smart_translate(Evas_Object *obj) +{ + evas_object_smart_callback_call(obj, SIG_LANG_CHANGED, NULL); + return EINA_TRUE; +} + +static Eina_Bool _elm_glview_smart_on_focus(Evas_Object *obj) { ELM_GLVIEW_DATA_GET(obj, sd); @@ -274,6 +283,7 @@ _elm_glview_smart_set_user(Elm_Glview_Smart_Class *sc) ELM_WIDGET_CLASS(sc)->base.resize = _elm_glview_smart_resize; ELM_WIDGET_CLASS(sc)->on_focus = _elm_glview_smart_on_focus; + ELM_WIDGET_CLASS(sc)->translate = _elm_glview_smart_translate; } EAPI const Elm_Glview_Smart_Class * diff --git a/src/lib/elm_glview.h b/src/lib/elm_glview.h index aa27382..e633a50 100644 --- a/src/lib/elm_glview.h +++ b/src/lib/elm_glview.h @@ -10,6 +10,10 @@ * has to deal with registering a few callback functions for rendering * to a surface using OpenGL APIs. * + * This widget emits the following signals, besides the ones sent from + * @ref GLView: + * - @c "language,changed" - the program's language changed + * * Below is an illustrative example of how to use GLView and and OpenGL * to render in elementary environment. * @ref glview_example_01_page