diff options
Diffstat (limited to 'src/libraries/winFang.h')
-rw-r--r-- | src/libraries/winFang.h | 29 |
1 files changed, 28 insertions, 1 deletions
diff --git a/src/libraries/winFang.h b/src/libraries/winFang.h index 1bdef20..edec11b 100644 --- a/src/libraries/winFang.h +++ b/src/libraries/winFang.h | |||
@@ -8,6 +8,8 @@ | |||
8 | /* Enable access to unstable EFL EO API. */ | 8 | /* Enable access to unstable EFL EO API. */ |
9 | #define EFL_EO_API_SUPPORT 1 | 9 | #define EFL_EO_API_SUPPORT 1 |
10 | 10 | ||
11 | #define ARRAY_LENGTH(array) (sizeof(array) / sizeof(*array)) | ||
12 | |||
11 | 13 | ||
12 | #include <Eo.h> | 14 | #include <Eo.h> |
13 | #include <Eina.h> | 15 | #include <Eina.h> |
@@ -24,6 +26,29 @@ | |||
24 | #define WF_SWALLOW "winFang/content" | 26 | #define WF_SWALLOW "winFang/content" |
25 | 27 | ||
26 | 28 | ||
29 | typedef struct _widgetSpec | ||
30 | { | ||
31 | char *name; | ||
32 | const Eo_Class *klass; | ||
33 | } widgetSpec; | ||
34 | |||
35 | #define WT_CHECK "check" | ||
36 | #define WT_BOX "box" | ||
37 | #define WT_BUTTON "button" | ||
38 | #define WT_FILES "files" | ||
39 | #define WT_ENTRY "entry" | ||
40 | #define WT_GRID "grid" | ||
41 | #define WT_HOVER "hoversel" | ||
42 | #define WT_IMAGE "image" | ||
43 | #define WT_LABEL "label" | ||
44 | #define WT_LAYOUT "layout" | ||
45 | #define WT_RADIO "radio" | ||
46 | #define WT_RECT "rectangle" | ||
47 | #define WT_TEXT "text" | ||
48 | #define WT_TEXTBOX "textbox" | ||
49 | #define WT_TOOLBAR "toolbar" | ||
50 | |||
51 | |||
27 | typedef struct _winFang | 52 | typedef struct _winFang |
28 | { | 53 | { |
29 | Evas *e; | 54 | Evas *e; |
@@ -48,6 +73,7 @@ typedef struct _winFang | |||
48 | typedef struct _Widget | 73 | typedef struct _Widget |
49 | { | 74 | { |
50 | char magic[8]; | 75 | char magic[8]; |
76 | char type[16]; | ||
51 | Evas_Object *obj; | 77 | Evas_Object *obj; |
52 | 78 | ||
53 | char *label, *look, *action, *help; | 79 | char *label, *look, *action, *help; |
@@ -67,6 +93,7 @@ void winFangShow(winFang *win); | |||
67 | void winFangCalcMinSize(winFang *win); | 93 | void winFangCalcMinSize(winFang *win); |
68 | void winFangDel(winFang *win); | 94 | void winFangDel(winFang *win); |
69 | 95 | ||
70 | Widget *widgetAdd(winFang *win, const Eo_Class *klass, char *title, int x, int y, int w, int h); | 96 | Widget *widgetAdd(winFang *win, char *type, char *title, int x, int y, int w, int h); |
97 | void widgetDel(Widget *wid); | ||
71 | 98 | ||
72 | #endif | 99 | #endif |