aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/libraries/winFang.h
blob: f3b4e451fd0fca6fe73a006ff5d117bbfd64a503 (plain)
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
53
54
55
56
57
58
59
60
61
62
63
#ifndef _WINFANG_H_
#define _WINFANG_H_


#define EFL_API_OVERRIDE 1
/* Enable access to unstable EFL API that are still in beta */
#define EFL_BETA_API_SUPPORT 1
/* Enable access to unstable EFL EO API. */
#define EFL_EO_API_SUPPORT 1


#include <Eo.h>
#include <Eina.h>
#include <Evas.h>
#include <Elementary.h>
#include <EPhysics.h>


typedef struct _winFang
{
  Evas		*e;
  struct _winFang *parent;
  Evas_Object	*win;
  Evas_Object	*title;
  Evas_Object	*bg;
  Evas_Object	*box;
  EPhysics_Body *body;
  Eina_Clist	widgets;
  Eina_Clist	winFangs;
  int		x, y, w, h;
  Eina_Bool	internal;

  Evas_Object *hand[4];

  Eina_Clist	node;
  void		*data;
  Evas_Smart_Cb on_del;
} winFang;

typedef struct _Widget
{
  char		magic[8];
  Evas_Object	*obj;

  char		*label, *look, *action, *help;
  // foreground / background colour
  // thing
  // types {}
  // skangCoord x, y, w, h

  Eina_Clist	node;
  void		*data;
  Evas_Smart_Cb on_del;
} Widget;

winFang *winFangAdd(winFang *parent, int x, int y, int w, int h, char *title, char *name, EPhysics_World *world);
void winFangHide(winFang *win);
void winFangShow(winFang *win);
void winFangDel(winFang *win);

Widget *widgetAdd(winFang *win, const Eo_Class *klass, Evas_Object *parent, char *title);

#endif