aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/elementary/efl_ui_text_factory_emoticons.c
blob: 55818af33d9345782560b3f1b6450dfb85238cb1 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#ifdef HAVE_CONFIG_H
# include "elementary_config.h"
#endif

#include <Elementary.h>
#include <Elementary_Cursor.h>
#include "elm_priv.h"

#define MY_CLASS EFL_UI_TEXT_FACTORY_EMOTICONS_CLASS

typedef struct _Efl_Ui_Text_Factory_Emoticons_Data Efl_Ui_Text_Factory_Emoticons_Data;

struct _Efl_Ui_Text_Factory_Emoticons_Data
{
   const char *name;
};

EOLIAN static Eo *
_efl_ui_text_factory_emoticons_efl_object_constructor(Eo *obj,
     Efl_Ui_Text_Factory_Emoticons_Data *pd EINA_UNUSED)
{
   obj = efl_constructor(efl_super(obj, MY_CLASS));
   return obj;
}

EOLIAN static void
_efl_ui_text_factory_emoticons_efl_object_destructor(Eo *obj,
     Efl_Ui_Text_Factory_Emoticons_Data *pd EINA_UNUSED)
{
   efl_destructor(efl_super(obj, MY_CLASS));
}


EOLIAN static Efl_Canvas_Object
*_efl_ui_text_factory_emoticons_efl_canvas_text_factory_create(
      Eo *obj EINA_UNUSED,
      Efl_Ui_Text_Factory_Emoticons_Data *pd EINA_UNUSED,
      Efl_Canvas_Object *object,
      const char *key)
{
   Eo *o;
   const char *style = elm_widget_style_get(object);

   o = edje_object_add(evas_object_evas_get(object));
   if (!_elm_theme_object_set
         (object, o, "text", key, style))
     _elm_theme_object_set
       (object, o, "text/emoticon", "wtf", style);
   return o;
}

#include "efl_ui_text_factory_emoticons.eo.c"