1 #ifndef ELM_WIDGET_PANEL_H
2 #define ELM_WIDGET_PANEL_H
4 #include "elm_interface_scrollable.h"
5 #include "elm_widget_layout.h"
7 /* DO NOT USE THIS HEADER UNLESS YOU ARE PREPARED FOR BREAKING OF YOUR
8 * CODE. THIS IS ELEMENTARY'S INTERNAL WIDGET API (for now) AND IS NOT
9 * FINAL. CALL elm_widget_api_check(ELM_INTERNAL_API_VERSION) TO CHECK
18 * @section elm-panel-class The Elementary Panel Class
20 * Elementary, besides having the @ref Panel widget, exposes its
21 * foundation -- the Elementary Panel Class -- in order to create other
22 * widgets which are a panel with some more logic on top.
26 * Base layout smart data extended with panel instance data.
28 typedef struct _Elm_Panel_Data Elm_Panel_Data;
29 struct _Elm_Panel_Data
31 Evas_Object *bx, *content;
34 Evas_Object *hit_rect, *panel_edje, *scr_edje;
35 Evas_Object *scr_panel, *scr_event;
38 Elm_Panel_Orient orient;
40 double content_size_ratio;
41 Evas_Coord down_x, down_y;
42 Evas_Coord handler_size;
46 Eina_Bool delete_me : 1;
47 Eina_Bool scrollable : 1;
55 #define ELM_PANEL_DATA_GET(o, sd) \
56 Elm_Panel_Data * sd = eo_data_scope_get(o, ELM_PANEL_CLASS)
58 #define ELM_PANEL_DATA_GET_OR_RETURN(o, ptr) \
59 ELM_PANEL_DATA_GET(o, ptr); \
60 if (EINA_UNLIKELY(!ptr)) \
62 CRI("No widget data for object %p (%s)", \
63 o, evas_object_type_get(o)); \
67 #define ELM_PANEL_DATA_GET_OR_RETURN_VAL(o, ptr, val) \
68 ELM_PANEL_DATA_GET(o, ptr); \
69 if (EINA_UNLIKELY(!ptr)) \
71 CRI("No widget data for object %p (%s)", \
72 o, evas_object_type_get(o)); \
76 #define ELM_PANEL_CHECK(obj) \
77 if (EINA_UNLIKELY(!eo_isa((obj), ELM_PANEL_CLASS))) \