1 #ifndef LUNCHER_H 2 #define LUNCHER_H 3 4 #include "e.h" 5 6 E_API extern E_Module_Api e_modapi; 7 8 E_API void *e_modapi_init (E_Module *m); 9 E_API int e_modapi_shutdown (E_Module *m); 10 E_API int e_modapi_save (E_Module *m); 11 12 typedef struct _Config Config; 13 typedef struct _Config_Item Config_Item; 14 typedef struct _Instance Instance; 15 typedef struct _Icon Icon; 16 typedef enum _Luncher_Type Luncher_Type; 17 18 enum _Luncher_Type 19 { 20 E_LUNCHER_MODULE_FULL = 0, 21 E_LUNCHER_MODULE_LAUNCH_ONLY, 22 E_LUNCHER_MODULE_TASKS_ONLY 23 }; 24 25 struct _Config 26 { 27 Eina_List *items; 28 29 E_Module *module; 30 Evas_Object *config_dialog; 31 Evas_Object *slist; 32 Evas_Object *list; 33 Evas_Object *general; 34 Evas_Object *contents; 35 Eina_Bool bar; 36 }; 37 38 struct _Config_Item 39 { 40 int id; 41 int version; 42 int preview_size; 43 int hide_tooltips; 44 Eina_Stringshare *dir; 45 Luncher_Type type; 46 }; 47 48 struct _Instance 49 { 50 Evas_Object *o_main; 51 Evas_Object *o_icon_con; 52 Evas_Object *drop_handler; 53 Evas_Object *place_holder; 54 Evas_Object *current_preview; 55 E_Order *order; 56 Eina_List *icons; 57 Eina_Hash *icons_desktop_hash; 58 Eina_Hash *icons_clients_hash; 59 Evas_Coord size; 60 Ecore_Job *resize_job; 61 Ecore_Job *recalc_job; 62 E_Comp_Object_Mover *iconify_provider; 63 Eina_Bool main_del; 64 Eina_Bool bar; 65 Eina_Bool inside; 66 Eina_Bool current_preview_menu; 67 Config_Item *cfg; 68 Icon *drop_before; 69 }; 70 71 struct _Icon 72 { 73 Instance *inst; 74 Evas_Object *o_layout; 75 Evas_Object *o_icon; 76 Evas_Object *preview; 77 Evas_Object *preview_box; 78 Evas_Object *preview_scroller; 79 Evas_Object *client_menu; 80 E_Exec_Instance *exec; 81 Efreet_Desktop *desktop; 82 Eina_List *execs; 83 Eina_List *clients; 84 Eina_List *client_cbs; 85 Ecore_Timer *mouse_in_timer; 86 Ecore_Timer *mouse_out_timer; 87 Ecore_Timer *drag_timer; 88 Eina_Stringshare *icon; 89 Eina_Stringshare *key; 90 Eina_Bool in_order; 91 Eina_Bool active; 92 Eina_Bool starting; 93 Eina_Bool preview_dismissed; 94 struct 95 { 96 unsigned char start E_BITFIELD; 97 unsigned char dnd E_BITFIELD; 98 int x, y; 99 } drag; 100 }; 101 102 EINTERN Evas_Object *config_luncher(E_Zone *zone, Instance *inst, Eina_Bool bar); 103 EINTERN Evas_Object *bar_create(Evas_Object *parent, int *id, E_Gadget_Site_Orient orient); 104 EINTERN void bar_reorder(Instance *inst); 105 EINTERN void bar_recalculate(Instance *inst); 106 EINTERN void bar_config_updated(Instance *inst); 107 EINTERN Evas_Object *grid_create(Evas_Object *parent, int *id, E_Gadget_Site_Orient orient); 108 EINTERN void grid_reorder(Instance *inst); 109 EINTERN void grid_recalculate(Instance *inst); 110 111 EINTERN extern Config *luncher_config; 112 EINTERN extern Eina_List *luncher_instances; 113 114 #endif 115