Evas_Object *bbl;
Evas_Object *content, *icon;
const char *label, *info, *corner;
-<<<<<<< HEAD
-=======
Elm_Bubble_Pos pos;
->>>>>>> remotes/origin/upstream
};
static const char *widtype = NULL;
{NULL, NULL}
};
-<<<<<<< HEAD
-=======
-static const char *corner_string[] =
+static const char *corner_string[] =
{
"top_left",
"top_right",
"bottom_right"
};
->>>>>>> remotes/origin/upstream
static void
_del_hook(Evas_Object *obj)
{
if (!wd) return;
_elm_widget_mirrored_reload(obj);
_mirrored_set(obj, elm_widget_mirrored_get(obj));
-<<<<<<< HEAD
- _elm_theme_object_set(obj, wd->bbl, "bubble", wd->corner,
-=======
_elm_theme_object_set(obj, wd->bbl, "bubble", corner_string[wd->pos],
->>>>>>> remotes/origin/upstream
elm_widget_style_get(obj));
- edje_object_part_text_set(wd->bbl, "elm.text", wd->label);
+ edje_object_part_text_escaped_set(wd->bbl, "elm.text", wd->label);
if (wd->label) edje_object_signal_emit(wd->bbl, "elm,state,text,visible", "elm");
else edje_object_signal_emit(wd->bbl, "elm,state,text,hidden", "elm");
- edje_object_part_text_set(wd->bbl, "elm.info", wd->info);
+ edje_object_part_text_escaped_set(wd->bbl, "elm.info", wd->info);
if (wd->info) edje_object_signal_emit(wd->bbl, "elm,state,info,visible", "elm");
else edje_object_signal_emit(wd->bbl, "elm,state,info,hidden", "elm");
if (wd->content)
if (!part || !strcmp(part, "default"))
_content_set(obj, content);
- else if(!strcmp(part, "icon"))
+ else if (!strcmp(part, "icon"))
_icon_set(obj, content);
}
if (!wd) return NULL;
if (!part || !strcmp(part, "default"))
return wd->content;
- else if(!strcmp(part, "icon"))
+ else if (!strcmp(part, "icon"))
return wd->icon;
return NULL;
}
if (!wd) return NULL;
if (!part || !strcmp(part, "default"))
return _content_unset(obj);
- else if(!strcmp(part, "icon"))
+ else if (!strcmp(part, "icon"))
return _icon_unset(obj);
return NULL;
}
if (!item || !strcmp(item, "default"))
{
eina_stringshare_replace(&wd->label, label);
- edje_object_part_text_set(wd->bbl, "elm.text", label);
+ edje_object_part_text_escaped_set(wd->bbl, "elm.text", label);
if (label) edje_object_signal_emit(wd->bbl, "elm,state,text,visible",
- "elm");
+ "elm");
else edje_object_signal_emit(wd->bbl, "elm,state,text,hidden", "elm");
_sizing_eval(obj);
}
else if (!strcmp(item, "info"))
{
eina_stringshare_replace(&wd->info, label);
- edje_object_part_text_set(wd->bbl, "elm.info", label);
+ edje_object_part_text_escaped_set(wd->bbl, "elm.info", label);
if (label) edje_object_signal_emit(wd->bbl, "elm,state,info,visible",
- "elm");
+ "elm");
else edje_object_signal_emit(wd->bbl, "elm,state,info,hidden", "elm");
_sizing_eval(obj);
}
elm_widget_content_unset_hook_set(obj, _content_unset_hook);
wd->corner = eina_stringshare_add("base");
-<<<<<<< HEAD
-=======
wd->pos = ELM_BUBBLE_POS_TOP_LEFT; //default
->>>>>>> remotes/origin/upstream
wd->bbl = edje_object_add(e);
elm_widget_resize_object_set(obj, wd->bbl);
return obj;
}
-<<<<<<< HEAD
-EAPI void
-elm_bubble_label_set(Evas_Object *obj, const char *label)
-{
- _elm_bubble_label_set(obj, NULL, label);
-}
-
-EAPI const char*
-elm_bubble_label_get(const Evas_Object *obj)
-{
- return _elm_bubble_label_get(obj, NULL);
-}
-
-EAPI void
-elm_bubble_info_set(Evas_Object *obj, const char *info)
-{
- _elm_bubble_label_set(obj, "info", info);
-}
-
-EAPI const char *
-elm_bubble_info_get(const Evas_Object *obj)
-{
- return _elm_bubble_label_get(obj, "info");
-}
-
-EAPI void
-elm_bubble_content_set(Evas_Object *obj, Evas_Object *content)
-{
- _content_set_hook(obj, NULL, content);
-}
-
-EAPI Evas_Object *
-elm_bubble_content_get(const Evas_Object *obj)
-{
- return _content_get_hook(obj, NULL);
-}
-
-EAPI Evas_Object *
-elm_bubble_content_unset(Evas_Object *obj)
-{
- return _content_unset_hook(obj, NULL);
-}
-
-EAPI void
-elm_bubble_icon_set(Evas_Object *obj, Evas_Object *icon)
-{
- _content_set_hook(obj, "icon", icon);
-}
-
-EAPI Evas_Object *
-elm_bubble_icon_get(const Evas_Object *obj)
-{
- return _content_get_hook(obj, "icon");
-}
-
-EAPI Evas_Object *
-elm_bubble_icon_unset(Evas_Object *obj)
-{
- return _content_unset_hook(obj, "icon");
-}
-
-EAPI void
-elm_bubble_corner_set(Evas_Object *obj, const char *corner)
-=======
-EINA_DEPRECATED EAPI void
-elm_bubble_corner_set(Evas_Object *obj, const char *corner)
-{
- int i = 0;
- for (i=ELM_BUBBLE_POS_TOP_LEFT; i<=ELM_BUBBLE_POS_BOTTOM_RIGHT; i++)
- {
- if (!strcmp(corner,corner_string[i]))
- elm_bubble_pos_set(obj, i);
- }
-}
-
EAPI void
elm_bubble_pos_set(Evas_Object *obj, Elm_Bubble_Pos pos)
->>>>>>> remotes/origin/upstream
{
ELM_CHECK_WIDTYPE(obj, widtype);
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return;
-<<<<<<< HEAD
- EINA_SAFETY_ON_NULL_RETURN(corner);
- eina_stringshare_replace(&wd->corner, corner);
- _theme_hook(obj);
-}
-
-EAPI const char*
-elm_bubble_corner_get(const Evas_Object *obj)
-{
- ELM_CHECK_WIDTYPE(obj, widtype) NULL;
- Widget_Data *wd = elm_widget_data_get(obj);
- if (!wd) return NULL;
- return wd->corner;
-=======
- if(pos<ELM_BUBBLE_POS_TOP_LEFT || pos>ELM_BUBBLE_POS_BOTTOM_RIGHT) return;
+ if (pos<ELM_BUBBLE_POS_TOP_LEFT || pos>ELM_BUBBLE_POS_BOTTOM_RIGHT) return;
wd->pos = pos;
_theme_hook(obj);
}
-EINA_DEPRECATED EAPI const char*
-elm_bubble_corner_get(const Evas_Object *obj)
-{
- return corner_string[elm_bubble_pos_get(obj)];
-}
-
EAPI Elm_Bubble_Pos
elm_bubble_pos_get(const Evas_Object *obj)
{
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return ELM_BUBBLE_POS_INVALID;
return wd->pos;
->>>>>>> remotes/origin/upstream
}