f0d936c0 |
1 | //FIXME by including ltt.h |
2 | #include <time.h> |
3 | typedef time_t ltt_time; |
17abcce3 |
4 | |
f0d936c0 |
5 | typedef struct _ltt_time_interval |
1e7cfdab |
6 | { |
f0d936c0 |
7 | ltt_time time_begin, time_end; |
8 | } ltt_time_interval; |
1e7cfdab |
9 | |
f0d936c0 |
10 | // ??? |
1e7cfdab |
11 | |
1e7cfdab |
12 | |
f0d936c0 |
13 | /* Setup the hooks */ |
14 | Draw_Before_Hooks = lttv_hooks_new(); |
15 | Draw_Event_Hooks = lttv_hooks_new(); |
16 | Draw_After_Hooks = lttv_hooks_new(); |
1e7cfdab |
17 | |
f0d936c0 |
18 | lttv_hooks_add(Draw_Before_Hooks, Draw_Before_Hook, NULL); |
19 | lttv_hooks_add(Draw_Event_Hooks, Draw_Event_Hook, NULL); |
20 | lttv_hooks_add(Draw_After_Hooks, Draw_After_Hook, NULL); |
f60d7a47 |
21 | |
f0d936c0 |
22 | /* Destroy the hooks */ |
1e7cfdab |
23 | |
f0d936c0 |
24 | lttv_hooks_destroy(Draw_Before_Hooks); |
25 | lttv_hooks_destroy(Draw_Event_Hooks); |
26 | lttv_hooks_destroy(Draw_After_Hooks); |
1e7cfdab |
27 | |
1e7cfdab |
28 | |
1e7cfdab |
29 | |
f60d7a47 |
30 | |
f0d936c0 |
31 | /***************************************************************************** |
32 | * Definition of structures * |
33 | *****************************************************************************/ |
f60d7a47 |
34 | |
f0d936c0 |
35 | /* Structure used to store and use information relative to one events refresh |
36 | * request. Typically filled in by the expose event callback, then passed to the |
37 | * library call, then used by the drawing hooks. Then, once all the events are |
38 | * sent, it is freed by the hook called after the reading. |
39 | */ |
40 | typedef struct _EventRequest |
1e7cfdab |
41 | { |
f0d936c0 |
42 | ControlFlowData *Control_Flow_Data; |
43 | ltt_time time_begin, time_end; |
44 | /* Fill the Events_Context during the initial expose, before calling for |
45 | * events. |
46 | */ |
47 | GArray Events_Context; //FIXME |
48 | } EventRequest ; |
1e7cfdab |
49 | |
1e7cfdab |
50 | |
1e7cfdab |
51 | |
f0d936c0 |
52 | /***************************************************************************** |
53 | * Function prototypes * |
54 | *****************************************************************************/ |
55 | //! Control Flow Viewer's constructor hook |
56 | GtkWidget *hGuiControlFlow(GtkWidget *pmParentWindow); |
57 | //! Control Flow Viewer's constructor |
58 | ControlFlowData *GuiControlFlow(void); |
59 | //! Control Flow Viewer's destructor |
60 | void GuiControlFlow_Destructor(ControlFlowData *Control_Flow_Data); |
1e7cfdab |
61 | |
f60d7a47 |
62 | |
f0d936c0 |
63 | static int Event_Selected_Hook(void *hook_data, void *call_data); |
f60d7a47 |
64 | |
f0d936c0 |
65 | static lttv_hooks |
66 | *Draw_Before_Hooks, |
67 | *Draw_Event_Hooks, |
68 | *Draw_After_Hooks; |
f60d7a47 |
69 | |
f0d936c0 |
70 | Draw_Before_Hook(void *hook_data, void *call_data) |
71 | Draw_Event_Hook(void *hook_data, void *call_data) |
72 | Draw_After_Hook(void *hook_data, void *call_data) |
f60d7a47 |
73 | |
f60d7a47 |
74 | |
f0d936c0 |
75 | //void Tree_V_set_cursor(ControlFlowData *Control_Flow_Data); |
76 | //void Tree_V_get_cursor(ControlFlowData *Control_Flow_Data); |
f60d7a47 |
77 | |
f0d936c0 |
78 | /* Prototype for selection handler callback */ |
79 | //static void tree_selection_changed_cb (GtkTreeSelection *selection, gpointer data); |
80 | static void v_scroll_cb (GtkAdjustment *adjustment, gpointer data); |
81 | //static void Tree_V_size_allocate_cb (GtkWidget *widget, GtkAllocation *alloc, gpointer data); |
82 | //static void Tree_V_size_request_cb (GtkWidget *widget, GtkRequisition *requisition, gpointer data); |
83 | //static void Tree_V_cursor_changed_cb (GtkWidget *widget, gpointer data); |
84 | //static void Tree_V_move_cursor_cb (GtkWidget *widget, GtkMovementStep arg1, gint arg2, gpointer data); |
f60d7a47 |
85 | |
f0d936c0 |
86 | static void expose_event_cb (GtkWidget *widget, GdkEventExpose *expose, gpointer data); |
f60d7a47 |
87 | |
f0d936c0 |
88 | void add_test_process(ControlFlowData *Control_Flow_Data); |
f60d7a47 |
89 | |
f0d936c0 |
90 | static void get_test_data(guint Event_Number, guint List_Height, |
91 | ControlFlowData *Control_Flow_Data); |
f60d7a47 |
92 | |
f0d936c0 |
93 | void add_test_data(ControlFlowData *Control_Flow_Data); |
94 | void test_draw(ControlFlowData *Control_Flow_Data); |
f60d7a47 |
95 | |
f0d936c0 |
96 | void Drawing_Area_Init(ControlFlowData *Control_Flow_Data); |
f60d7a47 |
97 | |
f60d7a47 |
98 | |
17abcce3 |
99 | /*\@}*/ |