elementary/ctxpopup - ctxpopup will be dismissed when the language is changed.
Author: hermet
Date: 2013-02-11 22:58:05 -0800 (Mon, 11 Feb 2013)
New Revision: 83841
Trac: http://trac.enlightenment.org/e/changeset/83841
Change-Id: Ic295d4148c977004db40bc25f42a7622a5cef07e
EAPI const char ELM_CTXPOPUP_SMART_NAME[] = "elm_ctxpopup";
static const char SIG_DISMISSED[] = "dismissed";
EAPI const char ELM_CTXPOPUP_SMART_NAME[] = "elm_ctxpopup";
static const char SIG_DISMISSED[] = "dismissed";
+static const char SIG_LANG_CHANGED[] = "language,changed";
+
static const Evas_Smart_Cb_Description _smart_callbacks[] = {
{SIG_DISMISSED, ""},
static const Evas_Smart_Cb_Description _smart_callbacks[] = {
{SIG_DISMISSED, ""},
+ {SIG_LANG_CHANGED, ""},
Elm_Layout_Smart_Class, elm_layout_smart_class_get, _smart_callbacks);
static Eina_Bool
Elm_Layout_Smart_Class, elm_layout_smart_class_get, _smart_callbacks);
static Eina_Bool
+_elm_ctxpopup_smart_translate(Evas_Object *obj)
+{
+ evas_object_hide(obj);
+}
+
+static Eina_Bool
_elm_ctxpopup_smart_focus_next(const Evas_Object *obj,
Elm_Focus_Direction dir,
Evas_Object **next)
_elm_ctxpopup_smart_focus_next(const Evas_Object *obj,
Elm_Focus_Direction dir,
Evas_Object **next)
ELM_WIDGET_CLASS(sc)->sub_object_add = _elm_ctxpopup_smart_sub_object_add;
ELM_WIDGET_CLASS(sc)->focus_next = _elm_ctxpopup_smart_focus_next;
ELM_WIDGET_CLASS(sc)->focus_direction = NULL;
ELM_WIDGET_CLASS(sc)->sub_object_add = _elm_ctxpopup_smart_sub_object_add;
ELM_WIDGET_CLASS(sc)->focus_next = _elm_ctxpopup_smart_focus_next;
ELM_WIDGET_CLASS(sc)->focus_direction = NULL;
+ ELM_WIDGET_CLASS(sc)->translate = _elm_ctxpopup_smart_translate;
ELM_CONTAINER_CLASS(sc)->content_get = _elm_ctxpopup_smart_content_get;
ELM_CONTAINER_CLASS(sc)->content_set = _elm_ctxpopup_smart_content_set;
ELM_CONTAINER_CLASS(sc)->content_get = _elm_ctxpopup_smart_content_get;
ELM_CONTAINER_CLASS(sc)->content_set = _elm_ctxpopup_smart_content_set;
*
* This widget emits the following signals, besides the ones sent from
* @ref Layout:
*
* This widget emits the following signals, besides the ones sent from
* @ref Layout:
- * - @c "dismissed" - the ctxpopup was dismissed
+ * - @c "dismissed" - this is called when the outside of ctxpopup was clicked or
+ * it's parent area is changed or the language is changed. and then ctxpopup is
+ * dismissed.
*
* Default content parts of the ctxpopup widget that you can use for are:
* @li "default" - A content of the ctxpopup
*
* Default content parts of the ctxpopup widget that you can use for are:
* @li "default" - A content of the ctxpopup