e969fd8e |
1 | #ifndef _MAIN_WINDOW_ |
2 | #define _MAIN_WINDOW_ |
3 | |
4 | #include <gtk/gtk.h> |
5 | |
6 | #include <ltt/ltt.h> |
7 | #include <lttv/attribute.h> |
8 | #include <lttv/traceset.h> |
9 | #include <lttv/processTrace.h> |
10 | |
11 | #include <lttv/common.h> |
12 | #include <lttv/gtkcustom.h> |
f7afe191 |
13 | #include <lttv/hook.h> |
14 | #include <lttv/stats.h> |
e969fd8e |
15 | |
36b3c068 |
16 | typedef struct _WindowCreationData { |
17 | int argc; |
18 | char ** argv; |
19 | } WindowCreationData; |
e969fd8e |
20 | |
f7afe191 |
21 | typedef struct _TimeWindow { |
22 | LttTime startTime; |
23 | LttTime Time_Width; |
24 | } TimeWindow; |
25 | |
26 | typedef struct _TracesetInfo { |
27 | gchar* path; |
28 | LttvHooks |
29 | *before_traceset, |
30 | *after_traceset, |
31 | *before_trace, |
32 | *after_trace, |
33 | *before_tracefile, |
34 | *after_tracefile, |
35 | *before_event, |
36 | *after_event; |
37 | //FIXME? TracesetContext and stats in same or different variable ? |
38 | LttvTracesetStats * TracesetContext; |
39 | LttvTraceset * traceset; |
40 | } TracesetInfo ; |
41 | |
42 | |
e969fd8e |
43 | struct _mainWindow{ |
44 | GtkWidget* MWindow; /* Main Window */ |
f7afe191 |
45 | // systemView * SystemView; /* System view displayed in this window*/ |
e969fd8e |
46 | |
47 | /* Status bar information */ |
48 | // guint MainSBarContextID; /* Context ID of main status bar */ |
49 | // guint BegTimeSBarContextID; /* Context ID of BegTime status bar */ |
50 | // guint EndTimeSBarContextID; /* Context ID of EndTime status bar */ |
51 | |
52 | /* Child windows */ |
53 | //openTracesetWindow* OpenTracesetWindow;/* Window to get prof and proc file*/ |
54 | //viewTimeFrameWindow* ViewTimeFrameWindow;/*Window to select time frame */ |
55 | //gotoEventWindow* GotoEventWindow; /*search for event description*/ |
56 | //openFilterWindow* OpenFilterWindow; /* Open a filter selection window */ |
57 | GtkWidget* HelpContents;/* Window to display help contents */ |
58 | GtkWidget* AboutBox; /* Window about information */ |
59 | |
f7afe191 |
60 | //LttvTracesetContext * traceset_context; |
61 | //LttvTraceset * traceset; /* trace set associated with the window */ |
e969fd8e |
62 | // lttv_trace_filter * filter; /* trace filter associated with the window */ |
e969fd8e |
63 | |
f7afe191 |
64 | /* Traceset related information */ |
65 | TracesetInfo * Traceset_Info; |
66 | /* Attributes for trace reading hooks local to the main window */ |
67 | LttvIAttribute * Attributes; |
68 | |
e969fd8e |
69 | tab * Tab; |
70 | tab * CurrentTab; |
36b3c068 |
71 | |
72 | WindowCreationData * winCreationData; |
e969fd8e |
73 | }; |
74 | |
75 | |
f7afe191 |
76 | //struct _systemView{ |
77 | // gpointer EventDB; |
78 | // gpointer SystemInfo; |
79 | // gpointer Options; |
80 | // mainWindow * Window; |
81 | // struct _systemView * Next; |
82 | //}; |
e969fd8e |
83 | |
84 | struct _tab{ |
85 | GtkWidget * label; |
86 | GtkCustom * custom; |
87 | |
f7afe191 |
88 | |
89 | // Will have to read directly at the main window level, as we want |
90 | // to be able to modify a traceset on the fly. |
91 | //LttTime traceStartTime; |
92 | //LttTime traceEndTime; |
93 | |
94 | // startTime is the left of the visible area. Corresponds to the scrollbar |
95 | // value. |
96 | // Time_Width is a zoom dependant value (corresponding to page size) |
97 | TimeWindow Time_Window; |
98 | |
99 | // The current time is the time selected in the visible area by the user, |
100 | // not the scrollbar value. |
e969fd8e |
101 | LttTime currentTime; |
102 | LttvIAttribute * Attributes; |
103 | |
104 | struct _tab * Next; |
105 | }; |
106 | |
107 | #endif /* _MAIN_WINDOW_ */ |
108 | |
109 | |