#include <ltt/ltt.h>
#include <gtk/gtk.h>
-typedef struct _mainWindow mainWindow;
+typedef struct _MainWindow MainWindow;
//typedef struct _systemView systemView;
-typedef struct _tab tab;
+typedef struct _Tab Tab;
/* constructor of the viewer */
-typedef GtkWidget * (*lttv_constructor)(mainWindow * main_window);
+typedef GtkWidget * (*lttv_constructor)(MainWindow * main_window);
typedef lttv_constructor view_constructor;
typedef struct _TimeWindow {
- LttTime startTime;
- LttTime Time_Width;
+ LttTime start_time;
+ LttTime time_width;
} TimeWindow;
#endif // COMMON_H
*/
// Not Needed : Main window add widget returned by constructor
-//void AttachViewer(mainWindow *main_win, GtkWidget *viewer);
+//void AttachViewer(MainWindow *main_win, GtkWidget *viewer);
/* ?? Maybe we do not need this function, when a widget is destroyed,
* @param viewer viewer to be detached from the current tab.
*/
-//void DetachViewer(mainWindow *main_win, GtkWidget *viewer);
+//void DetachViewer(MainWindow *main_win, GtkWidget *viewer);
/**
* @param info the message which will be shown in the status bar.
*/
-void UpdateStatus(mainWindow *main_win, char *info);
+void UpdateStatus(MainWindow *main_win, char *info);
/**
* @param time_interval a pointer where time interval will be stored.
*/
-void GetTimeWindow(mainWindow *main_win, TimeWindow *time_window);
+void GetTimeWindow(MainWindow *main_win, TimeWindow *time_window);
/**
* @param time_interval a pointer where time interval is stored.
*/
-void SetTimeWindow(mainWindow *main_win, TimeWindow *time_window);
+void SetTimeWindow(MainWindow *main_win, TimeWindow *time_window);
/**
* Function to get the time span of the main window's traceset.
*/
-void GetTracesetTimeSpan(mainWindow *main_win, TimeInterval *time_interval);
+void GetTracesetTimeSpan(MainWindow *main_win, TimeInterval *time_interval);
/**
* Function to get the current time/event of the current tab.
* @param time a pointer where time will be stored.
*/
-void GetCurrentTime(mainWindow *main_win, LttTime *time);
+void GetCurrentTime(MainWindow *main_win, LttTime *time);
/**
* @param time a pointer where time is stored.
*/
-void SetCurrentTime(mainWindow *main_win, LttTime *time);
+void SetCurrentTime(MainWindow *main_win, LttTime *time);
/**
* @param traceset a pointer to a traceset.
*/
-//void GetTraceset(mainWindow *main_win, Traceset *traceset);
+//void GetTraceset(MainWindow *main_win, Traceset *traceset);
/**
* @param filter, a pointer to a filter.
*/
-//void GetFilter(mainWindow *main_win, Filter *filter);
+//void GetFilter(MainWindow *main_win, Filter *filter);
/**
*/
void RegUpdateTimeInterval(LttvHook hook, gpointer hook_data,
- mainWindow * main_win);
+ MainWindow * main_win);
/**
*/
void UnregUpdateTimeInterval(LttvHook hook, gpointer hook_data,
- mainWindow * main_win);
+ MainWindow * main_win);
/**
*/
void RegUpdateTraceset(LttvHook hook, gpointer hook_data,
- mainWindow * main_win);
+ MainWindow * main_win);
/**
*/
void UnregUpdateTraceset(LttvHook hook, gpointer hook_data,
- mainWindow * main_win);
+ MainWindow * main_win);
/**
*/
void RegUpdateFilter(LttvHook hook, gpointer hook_data,
- mainWindow *main_win);
+ MainWindow *main_win);
/**
*/
void UnregUpdateFilter(LttvHook hook, gpointer hook_data,
- mainWindow * main_win);
+ MainWindow * main_win);
/**
*/
void RegUpdateCurrentTime(LttvHook hook, gpointer hook_data,
- mainWindow *main_win);
+ MainWindow *main_win);
/**
*/
void UnregUpdateCurrentTime(LttvHook hook, gpointer hook_data,
- mainWindow * main_win);
+ MainWindow * main_win);
/**
* @param paned a pointer to a pane where the viewer is contained.
*/
-void SetFocusedPane(mainWindow *main_win, gpointer paned);
+void SetFocusedPane(MainWindow *main_win, gpointer paned);
/**
*/
void RegUpdateDividor(LttvHook hook, gpointer hook_data,
- mainWindow *main_win);
+ MainWindow *main_win);
/**
*/
void UnregUpdateDividor(LttvHook hook, gpointer hook_data,
- mainWindow *main_win);
+ MainWindow *main_win);
/**
* @param position position of the hpane's dividor.
*/
-void SetHPaneDividor(mainWindow *main_win, gint position);
+void SetHPaneDividor(MainWindow *main_win, gint position);
/**
* @param end the end time of the last event to be processed.
*/
-void processTraceset(mainWindow *main_win, LttTime start,
+void processTraceset(MainWindow *main_win, LttTime start,
LttTime end, unsigned maxNumEvents);
* @param LttvHooks hooks to be registered.
*/
-void contextAddHooks(mainWindow *main_win ,
+void contextAddHooks(MainWindow *main_win ,
LttvHooks *before_traceset,
LttvHooks *after_traceset,
LttvHooks *check_trace,
* @param LttvHooks hooks to be registered.
*/
-void contextRemoveHooks(mainWindow *main_win ,
+void contextRemoveHooks(MainWindow *main_win ,
LttvHooks *before_traceset,
LttvHooks *after_traceset,
LttvHooks *check_trace,
* @param end end time of the traceset.
*/
-void getTracesetTimeSpan(mainWindow *main_win, TimeInterval *time_span);
+void getTracesetTimeSpan(MainWindow *main_win, TimeInterval *time_span);
/**
* @param main_win the main window the viewer belongs to.
*/
-void stateAddEventHooks(mainWindow *main_win );
-void stateRemoveEventHooks(mainWindow *main_win );
+void stateAddEventHooks(MainWindow *main_win );
+void stateRemoveEventHooks(MainWindow *main_win );
/**
* @param main_win the main window the viewer belongs to.
*/
-void statsAddEventHooks(mainWindow *main_win );
-void statsRemoveEventHooks(mainWindow *main_win );
+void statsAddEventHooks(MainWindow *main_win );
+void statsRemoveEventHooks(MainWindow *main_win );
/**
* @param main_win the main window the viewer belongs to.
*/
-LttvTracesetStats* getTracesetStats(mainWindow *main_win);
+LttvTracesetStats* getTracesetStats(MainWindow *main_win);
GtkPaned container;
/*< public >*/
- GtkPaned * firstPane;
- GtkPaned * lastPane;
- GtkPaned * focusedPane;
- guint numChildren;
+ GtkPaned * first_pane;
+ GtkPaned * last_pane;
+ GtkPaned * focused_pane;
+ guint num_children;
GtkWidget * vbox;
// GtkWidget * scrollWindow;
// GtkWidget * viewport;
- GtkWidget * hScrollbar;
- GtkAdjustment *hAdjust;
- mainWindow * mw;
+ GtkWidget * hscrollbar;
+ GtkAdjustment *hadjust;
+ MainWindow * mw;
};
struct _GtkCustomClass
*before_event,
*after_event;
//FIXME? TracesetContext and stats in same or different variable ?
- LttvTracesetStats * TracesetContext;
+ LttvTracesetStats * traceset_context;
LttvTraceset * traceset;
} TracesetInfo ;
-struct _mainWindow{
- GtkWidget* MWindow; /* Main Window */
+struct _MainWindow{
+ GtkWidget* mwindow; /* Main Window */
/* Status bar information */
// guint MainSBarContextID; /* Context ID of main status bar */
//viewTimeFrameWindow* ViewTimeFrameWindow;/*Window to select time frame */
//gotoEventWindow* GotoEventWindow; /*search for event description*/
//openFilterWindow* OpenFilterWindow; /* Open a filter selection window */
- GtkWidget* HelpContents;/* Window to display help contents */
- GtkWidget* AboutBox; /* Window about information */
+ GtkWidget* help_contents;/* Window to display help contents */
+ GtkWidget* about_box; /* Window about information */
// lttv_trace_filter * filter; /* trace filter associated with the window */
/* Traceset related information */
- TracesetInfo * Traceset_Info;
+ TracesetInfo * traceset_info;
/* Attributes for trace reading hooks local to the main window */
- LttvIAttribute * Attributes;
+ LttvIAttribute * attributes;
- tab * Tab;
- tab * CurrentTab;
+ Tab * tab;
+ Tab * current_tab;
- WindowCreationData * winCreationData;
+ WindowCreationData * win_creation_data;
GHashTable * hash_menu_item;
GHashTable * hash_toolbar_item;
};
-struct _tab{
+struct _Tab{
GtkWidget * label;
GtkCustom * custom;
// startTime is the left of the visible area. Corresponds to the scrollbar
// value.
// Time_Width is a zoom dependant value (corresponding to page size)
- TimeWindow Time_Window;
+ TimeWindow time_window;
// The current time is the time selected in the visible area by the user,
// not the scrollbar value.
- LttTime currentTime;
- LttvIAttribute * Attributes;
+ LttTime current_time;
+ LttvIAttribute * attributes;
- struct _tab * Next;
- mainWindow * mw;
+ struct _Tab * next;
+ MainWindow * mw;
};
/**
* @param traceset traceset of the main window.
*/
-void SetTraceset(mainWindow * main_win, gpointer traceset)
+void SetTraceset(MainWindow * main_win, gpointer traceset)
{
LttvHooks * tmp;
LttvAttributeValue value;
- g_assert(lttv_iattribute_find_by_path(main_win->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->attributes,
"hooks/updatetraceset", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL)return;
* @param filter filter of the main window.
*/
-void SetFilter(mainWindow * main_win, gpointer filter)
+void SetFilter(MainWindow * main_win, gpointer filter)
{
LttvHooks * tmp;
LttvAttributeValue value;
- g_assert(lttv_iattribute_find_by_path(main_win->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->attributes,
"hooks/updatefilter", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
* @param info the message which will be shown in the status bar.
*/
-void UpdateStatus(mainWindow *main_win, char *info)
+void UpdateStatus(MainWindow *main_win, char *info)
{
}
* @param time_interval a pointer where time interval will be stored.
*/
-void GetTimeWindow(mainWindow *main_win, TimeWindow *time_window)
+void GetTimeWindow(MainWindow *main_win, TimeWindow *time_window)
{
- //time_window->startTime = main_win->CurrentTab->Time_Window.startTime;
- //time_window->Time_Width = main_win->CurrentTab->Time_Window.Time_Width;
- *time_window = main_win->CurrentTab->Time_Window;
+ //time_window->start_time = main_win->current_tab->time_window.start_time;
+ //time_window->time_width = main_win->current_tab->time_window.time_width;
+ *time_window = main_win->current_tab->time_window;
}
/**
* @param time_interval a pointer where time interval will be stored.
*/
-void getTracesetTimeSpan(mainWindow *main_win, TimeInterval *time_interval)
+void getTracesetTimeSpan(MainWindow *main_win, TimeInterval *time_interval)
{
- //time_window->startTime = main_win->CurrentTab->Time_Window.startTime;
- //time_window->Time_Width = main_win->CurrentTab->Time_Window.Time_Width;
- *time_interval = *(LTTV_TRACESET_CONTEXT(main_win->Traceset_Info->TracesetContext)->Time_Span);
+ //time_window->start_time = main_win->current_tab->time_window.start_time;
+ //time_window->time_width = main_win->current_tab->time_window.time_width;
+ *time_interval = *(LTTV_TRACESET_CONTEXT(main_win->traceset_info->traceset_context)->Time_Span);
}
* @param time_interval a pointer where time interval is stored.
*/
-void SetTimeWindow(mainWindow *main_win, TimeWindow *time_window)
+void SetTimeWindow(MainWindow *main_win, TimeWindow *time_window)
{
LttvAttributeValue value;
LttvHooks * tmp;
- main_win->CurrentTab->Time_Window = *time_window;
- g_assert(lttv_iattribute_find_by_path(main_win->CurrentTab->Attributes,
+ main_win->current_tab->time_window = *time_window;
+ g_assert(lttv_iattribute_find_by_path(main_win->current_tab->attributes,
"hooks/updatetimewindow", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL) return;
* @param time a pointer where time will be stored.
*/
-void GetCurrentTime(mainWindow *main_win, LttTime *time)
+void GetCurrentTime(MainWindow *main_win, LttTime *time)
{
- time = &main_win->CurrentTab->currentTime;
+ time = &main_win->current_tab->current_time;
}
* @param time a pointer where time is stored.
*/
-void SetCurrentTime(mainWindow *main_win, LttTime *time)
+void SetCurrentTime(MainWindow *main_win, LttTime *time)
{
LttvAttributeValue value;
LttvHooks * tmp;
- main_win->CurrentTab->currentTime = *time;
- g_assert(lttv_iattribute_find_by_path(main_win->CurrentTab->Attributes,
+ main_win->current_tab->current_time = *time;
+ g_assert(lttv_iattribute_find_by_path(main_win->current_tab->attributes,
"hooks/updatecurrenttime", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
* @param traceset a pointer to a traceset.
*/
/*
-void GetTraceset(mainWindow *main_win, Traceset *traceset)
+void GetTraceset(MainWindow *main_win, Traceset *traceset)
{
}
*/
* @param filter, a pointer to a filter.
*/
/*
-void GetFilter(mainWindow *main_win, Filter *filter)
+void GetFilter(MainWindow *main_win, Filter *filter)
{
}
*/
*/
void RegUpdateTimeWindow(LttvHook hook, gpointer hook_data,
- mainWindow * main_win)
+ MainWindow * main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->CurrentTab->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->current_tab->attributes,
"hooks/updatetimewindow", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL){
*/
void UnregUpdateTimeWindow(LttvHook hook, gpointer hook_data,
- mainWindow * main_win)
+ MainWindow * main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->CurrentTab->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->current_tab->attributes,
"hooks/updatetimewindow", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL) return;
*/
void RegUpdateTraceset(LttvHook hook, gpointer hook_data,
- mainWindow * main_win)
+ MainWindow * main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->attributes,
"hooks/updatetraceset", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL){
*/
void UnregUpdateTraceset(LttvHook hook, gpointer hook_data,
- mainWindow * main_win)
+ MainWindow * main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->attributes,
"hooks/updatetraceset", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL) return;
*/
void RegUpdateFilter(LttvHook hook, gpointer hook_data,
- mainWindow *main_win)
+ MainWindow *main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->attributes,
"hooks/updatefilter", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL){
*/
void UnregUpdateFilter(LttvHook hook, gpointer hook_data,
- mainWindow * main_win)
+ MainWindow * main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->attributes,
"hooks/updatefilter", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL) return;
*/
void RegUpdateCurrentTime(LttvHook hook, gpointer hook_data,
- mainWindow *main_win)
+ MainWindow *main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->CurrentTab->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->current_tab->attributes,
"hooks/updatecurrenttime", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL){
*/
void UnregUpdateCurrentTime(LttvHook hook, gpointer hook_data,
- mainWindow * main_win)
+ MainWindow * main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->CurrentTab->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->current_tab->attributes,
"hooks/updatecurrenttime", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL) return;
* @param paned a pointer to a pane where the viewer is contained.
*/
-void SetFocusedPane(mainWindow *main_win, gpointer paned)
+void SetFocusedPane(MainWindow *main_win, gpointer paned)
{
- gtk_custom_set_focus((GtkWidget*)main_win->CurrentTab->custom,paned);
+ gtk_custom_set_focus((GtkWidget*)main_win->current_tab->custom,paned);
}
*/
void RegUpdateDividor(LttvHook hook, gpointer hook_data,
- mainWindow *main_win)
+ MainWindow *main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->CurrentTab->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->current_tab->attributes,
"hooks/hpanedividor", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL){
*/
void UnregUpdateDividor(LttvHook hook, gpointer hook_data,
- mainWindow *main_win)
+ MainWindow *main_win)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->CurrentTab->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->current_tab->attributes,
"hooks/hpanedividor", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL) return;
* @param position position of the hpane's dividor.
*/
-void SetHPaneDividor(mainWindow *main_win, gint position)
+void SetHPaneDividor(MainWindow *main_win, gint position)
{
LttvAttributeValue value;
LttvHooks * tmp;
- g_assert(lttv_iattribute_find_by_path(main_win->CurrentTab->Attributes,
+ g_assert(lttv_iattribute_find_by_path(main_win->current_tab->attributes,
"hooks/hpanedividor", LTTV_POINTER, &value));
tmp = (LttvHooks*)*(value.v_pointer);
if(tmp == NULL) return;
* @param end the end time of the last event to be processed.
*/
-void processTraceset(mainWindow *main_win, LttTime start,
+void processTraceset(MainWindow *main_win, LttTime start,
LttTime end, unsigned maxNumEvents)
{
- lttv_process_traceset_seek_time(main_win->Traceset_Info->TracesetContext, start);
- lttv_process_traceset(main_win->Traceset_Info->TracesetContext, end, maxNumEvents);
+ lttv_process_traceset_seek_time(main_win->traceset_info->traceset_context, start);
+ lttv_process_traceset(main_win->traceset_info->traceset_context, end, maxNumEvents);
}
/**
* @param LttvHooks hooks to be registered.
*/
-void contextAddHooks(mainWindow *main_win ,
+void contextAddHooks(MainWindow *main_win ,
LttvHooks *before_traceset,
LttvHooks *after_traceset,
LttvHooks *check_trace,
LttvHooks *after_event)
{
LttvTracesetContext * tsc =
- LTTV_TRACESET_CONTEXT(main_win->Traceset_Info->TracesetContext);
+ LTTV_TRACESET_CONTEXT(main_win->traceset_info->traceset_context);
lttv_traceset_context_add_hooks(tsc,before_traceset,after_traceset,
check_trace,before_trace,after_trace,
check_tracefile,before_tracefile,after_tracefile,
* @param LttvHooks hooks to be registered.
*/
-void contextRemoveHooks(mainWindow *main_win ,
+void contextRemoveHooks(MainWindow *main_win ,
LttvHooks *before_traceset,
LttvHooks *after_traceset,
LttvHooks *check_trace,
LttvHooks *after_event)
{
LttvTracesetContext * tsc =
- LTTV_TRACESET_CONTEXT(main_win->Traceset_Info->TracesetContext);
+ LTTV_TRACESET_CONTEXT(main_win->traceset_info->traceset_context);
lttv_traceset_context_remove_hooks(tsc,before_traceset,after_traceset,
check_trace,before_trace,after_trace,
check_tracefile,before_tracefile,after_tracefile,
* @param main_win the main window the viewer belongs to.
*/
-void stateAddEventHooks(mainWindow *main_win )
+void stateAddEventHooks(MainWindow *main_win )
{
lttv_state_add_event_hooks(
- (LttvTracesetState*)main_win->Traceset_Info->TracesetContext);
+ (LttvTracesetState*)main_win->traceset_info->traceset_context);
}
-void stateRemoveEventHooks(mainWindow *main_win )
+void stateRemoveEventHooks(MainWindow *main_win )
{
lttv_state_remove_event_hooks(
- (LttvTracesetState*)main_win->Traceset_Info->TracesetContext);
+ (LttvTracesetState*)main_win->traceset_info->traceset_context);
}
* @param main_win the main window the viewer belongs to.
*/
-void statsAddEventHooks(mainWindow *main_win )
+void statsAddEventHooks(MainWindow *main_win )
{
lttv_stats_add_event_hooks(
- (LttvTracesetStats*)main_win->Traceset_Info->TracesetContext);
+ (LttvTracesetStats*)main_win->traceset_info->traceset_context);
}
-void statsRemoveEventHooks(mainWindow *main_win )
+void statsRemoveEventHooks(MainWindow *main_win )
{
lttv_stats_remove_event_hooks(
- (LttvTracesetStats*)main_win->Traceset_Info->TracesetContext);
+ (LttvTracesetStats*)main_win->traceset_info->traceset_context);
}
/**
* @param main_win the main window the viewer belongs to.
*/
-LttvTracesetStats* getTracesetStats(mainWindow *main_win)
+LttvTracesetStats* getTracesetStats(MainWindow *main_win)
{
- return main_win->Traceset_Info->TracesetContext;
+ return main_win->traceset_info->traceset_context;
}
#define PATH_LENGTH 256
#define DEFAULT_TIME_WIDTH_S 1
-//extern LttvTracesetContext * gTracesetContext;
extern LttTrace *g_init_trace ;
static int g_win_count = 0;
-mainWindow * get_window_data_struct(GtkWidget * widget);
+MainWindow * get_window_data_struct(GtkWidget * widget);
char * get_unload_module(char ** loaded_module_name, int nb_module);
char * get_remove_trace(char ** all_trace_name, int nb_trace);
char * get_selection(char ** all_name, int nb, char *title, char * column_title);
void insert_viewer(GtkWidget* widget, view_constructor constructor)
{
GtkCustom * custom;
- mainWindow * mw_data;
+ MainWindow * mw_data;
GtkWidget * viewer;
mw_data = get_window_data_struct(widget);
- if(!mw_data->CurrentTab) return;
- custom = mw_data->CurrentTab->custom;
+ if(!mw_data->current_tab) return;
+ custom = mw_data->current_tab->custom;
viewer = (GtkWidget*)constructor(mw_data);
if(viewer)
}
}
-mainWindow * get_window_data_struct(GtkWidget * widget)
+MainWindow * get_window_data_struct(GtkWidget * widget)
{
GtkWidget * mw;
- mainWindow * mw_data;
+ MainWindow * mw_data;
mw = lookup_widget(widget, "MWindow");
if(mw == NULL){
return;
}
- mw_data = (mainWindow *) g_object_get_data(G_OBJECT(mw),"mainWindow");
+ mw_data = (MainWindow *) g_object_get_data(G_OBJECT(mw),"mainWindow");
if(mw_data == NULL){
g_printf("Main window data does not exist\n");
return;
void create_new_window(GtkWidget* widget, gpointer user_data, gboolean clone)
{
- mainWindow * parent = get_window_data_struct(widget);
+ MainWindow * parent = get_window_data_struct(widget);
if(clone){
g_printf("Clone : use the same traceset\n");
construct_main_window(parent, NULL, FALSE);
}else{
g_printf("Empty : traceset is set to NULL\n");
- construct_main_window(NULL, parent->winCreationData, FALSE);
+ construct_main_window(NULL, parent->win_creation_data, FALSE);
}
}
void move_up_viewer(GtkWidget * widget, gpointer user_data)
{
- mainWindow * mw = get_window_data_struct(widget);
- if(!mw->CurrentTab) return;
- gtk_custom_widget_move_up(mw->CurrentTab->custom);
+ MainWindow * mw = get_window_data_struct(widget);
+ if(!mw->current_tab) return;
+ gtk_custom_widget_move_up(mw->current_tab->custom);
}
void move_down_viewer(GtkWidget * widget, gpointer user_data)
{
- mainWindow * mw = get_window_data_struct(widget);
- if(!mw->CurrentTab) return;
- gtk_custom_widget_move_down(mw->CurrentTab->custom);
+ MainWindow * mw = get_window_data_struct(widget);
+ if(!mw->current_tab) return;
+ gtk_custom_widget_move_down(mw->current_tab->custom);
}
void delete_viewer(GtkWidget * widget, gpointer user_data)
{
- mainWindow * mw = get_window_data_struct(widget);
- if(!mw->CurrentTab) return;
- gtk_custom_widget_delete(mw->CurrentTab->custom);
+ MainWindow * mw = get_window_data_struct(widget);
+ if(!mw->current_tab) return;
+ gtk_custom_widget_delete(mw->current_tab->custom);
}
void open_traceset(GtkWidget * widget, gpointer user_data)
char ** dir;
gint id;
LttvTraceset * traceset;
- mainWindow * mw_data = get_window_data_struct(widget);
+ MainWindow * mw_data = get_window_data_struct(widget);
GtkFileSelection * file_selector =
(GtkFileSelection *)gtk_file_selection_new("Select a traceset");
LttvTraceset * traceset;
char * dir;
gint id;
- mainWindow * mw_data = get_window_data_struct(widget);
+ MainWindow * mw_data = get_window_data_struct(widget);
GtkDirSelection * file_selector = (GtkDirSelection *)gtk_dir_selection_new("Select a trace");
gtk_dir_selection_hide_fileop_buttons(file_selector);
trace = ltt_trace_open(dir);
if(trace == NULL) g_critical("cannot open trace %s", dir);
trace_v = lttv_trace_new(trace);
- traceset = mw_data->Traceset_Info->traceset;
- if(mw_data->Traceset_Info->TracesetContext != NULL){
- lttv_context_fini(LTTV_TRACESET_CONTEXT(mw_data->Traceset_Info->TracesetContext));
- g_object_unref(mw_data->Traceset_Info->TracesetContext);
+ traceset = mw_data->traceset_info->traceset;
+ if(mw_data->traceset_info->traceset_context != NULL){
+ lttv_context_fini(LTTV_TRACESET_CONTEXT(mw_data->traceset_info->traceset_context));
+ g_object_unref(mw_data->traceset_info->traceset_context);
}
lttv_traceset_add(traceset, trace_v);
- mw_data->Traceset_Info->TracesetContext =
+ mw_data->traceset_info->traceset_context =
g_object_new(LTTV_TRACESET_STATS_TYPE, NULL);
lttv_context_init(
- LTTV_TRACESET_CONTEXT(mw_data->Traceset_Info->TracesetContext),traceset);
+ LTTV_TRACESET_CONTEXT(mw_data->traceset_info->traceset_context),traceset);
case GTK_RESPONSE_REJECT:
case GTK_RESPONSE_CANCEL:
default:
LttvTraceset * traceset;
gint i, nb_trace;
char ** name, *remove_trace_name;
- mainWindow * mw_data = get_window_data_struct(widget);
+ MainWindow * mw_data = get_window_data_struct(widget);
- nb_trace =lttv_traceset_number(mw_data->Traceset_Info->traceset);
+ nb_trace =lttv_traceset_number(mw_data->traceset_info->traceset);
name = g_new(char*,nb_trace);
for(i = 0; i < nb_trace; i++){
- trace_v = lttv_traceset_get(mw_data->Traceset_Info->traceset, i);
+ trace_v = lttv_traceset_get(mw_data->traceset_info->traceset, i);
trace = lttv_trace(trace_v);
name[i] = trace->pathname;
}
if(remove_trace_name){
for(i=0; i<nb_trace; i++){
if(strcmp(remove_trace_name,name[i]) == 0){
- traceset = mw_data->Traceset_Info->traceset;
- if(mw_data->Traceset_Info->TracesetContext != NULL){
- lttv_context_fini(LTTV_TRACESET_CONTEXT(mw_data->Traceset_Info->TracesetContext));
- g_object_unref(mw_data->Traceset_Info->TracesetContext);
+ traceset = mw_data->traceset_info->traceset;
+ if(mw_data->traceset_info->traceset_context != NULL){
+ lttv_context_fini(LTTV_TRACESET_CONTEXT(mw_data->traceset_info->traceset_context));
+ g_object_unref(mw_data->traceset_info->traceset_context);
}
lttv_traceset_remove(traceset, i);
- mw_data->Traceset_Info->TracesetContext =
+ mw_data->traceset_info->traceset_context =
g_object_new(LTTV_TRACESET_STATS_TYPE, NULL);
lttv_context_init(
- LTTV_TRACESET_CONTEXT(mw_data->Traceset_Info->TracesetContext),traceset);
+ LTTV_TRACESET_CONTEXT(mw_data->traceset_info->traceset_context),traceset);
break;
}
}
on_close_activate (GtkMenuItem *menuitem,
gpointer user_data)
{
- mainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
+ MainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
main_window_destructor(mw_data);
}
{
int count = 0;
GtkWidget * notebook;
- tab * tmp;
- mainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
+ Tab * tmp;
+ MainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
notebook = lookup_widget((GtkWidget*)menuitem, "MNotebook");
if(notebook == NULL){
g_printf("Notebook does not exist\n");
return;
}
- if(mw_data->Tab == mw_data->CurrentTab){
- // tmp = mw_data->CurrentTab;
- // mw_data->Tab = mw_data->CurrentTab->Next;
+ if(mw_data->tab == mw_data->current_tab){
+ // tmp = mw_data->current_tb;
+ // mw_data->tab = mw_data->current_tab->next;
g_printf("The default TAB can not be deleted\n");
return;
}else{
- tmp = mw_data->Tab;
- while(tmp != mw_data->CurrentTab){
- tmp = tmp->Next;
+ tmp = mw_data->tab;
+ while(tmp != mw_data->current_tab){
+ tmp = tmp->next;
count++;
}
}
char ** dir;
gint id;
char str[PATH_LENGTH], *str1;
- mainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
+ MainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
GtkFileSelection * file_selector = (GtkFileSelection *)gtk_file_selection_new("Select a module");
gtk_file_selection_hide_fileop_buttons(file_selector);
str1 = strrchr(str,'\\');
str1++;
}
- if(mw_data->winCreationData)
- lttv_module_load(str1, mw_data->winCreationData->argc,mw_data->winCreationData->argv);
+ if(mw_data->win_creation_data)
+ lttv_module_load(str1, mw_data->win_creation_data->argc,mw_data->win_creation_data->argv);
else
lttv_module_load(str1, 0,NULL);
g_slist_foreach(g_main_window_list, insert_menu_toolbar_item, NULL);
char **name, *unload_module_name;
guint nb;
LttvModule ** modules, *module;
- mainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
+ MainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
modules = lttv_module_list(&nb);
name = g_new(char*, nb);
char * dir;
gint id;
- mainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
+ MainWindow * mw_data = get_window_data_struct((GtkWidget*)menuitem);
id = gtk_dialog_run(GTK_DIALOG(file_selector));
switch(id){
on_MWindow_destroy (GtkObject *object,
gpointer user_data)
{
- mainWindow *Main_Window = (mainWindow*)user_data;
+ MainWindow *Main_Window = (MainWindow*)user_data;
g_printf("There are : %d windows\n",g_slist_length(g_main_window_list));
guint page_num,
gpointer user_data)
{
- mainWindow * mw = get_window_data_struct((GtkWidget*)notebook);
- tab * Tab = mw->Tab;
+ MainWindow * mw = get_window_data_struct((GtkWidget*)notebook);
+ Tab * tab = mw->tab;
while(page_num){
- Tab = Tab->Next;
+ tab = tab->next;
page_num--;
}
- mw->CurrentTab = Tab;
+ mw->current_tab = tab;
}
char * get_remove_trace(char ** all_trace_name, int nb_trace)
}
-void insert_menu_toolbar_item(mainWindow * mw, gpointer user_data)
+void insert_menu_toolbar_item(MainWindow * mw, gpointer user_data)
{
int i;
GdkPixbuf *pixbuf;
tmp = g_hash_table_lookup(mw->hash_menu_item, g_strdup(menu_item->menuText));
if(tmp)continue;
constructor = menu_item->con;
- tool_menu_title_menu = lookup_widget(mw->MWindow,"ToolMenuTitle_menu");
+ tool_menu_title_menu = lookup_widget(mw->mwindow,"ToolMenuTitle_menu");
insert_view = gtk_menu_item_new_with_mnemonic (menu_item->menuText);
gtk_widget_show (insert_view);
gtk_container_add (GTK_CONTAINER (tool_menu_title_menu), insert_view);
tmp = g_hash_table_lookup(mw->hash_toolbar_item, g_strdup(toolbar_item->tooltip));
if(tmp)continue;
constructor = toolbar_item->con;
- tool_menu_title_menu = lookup_widget(mw->MWindow,"MToolbar2");
+ tool_menu_title_menu = lookup_widget(mw->mwindow,"MToolbar2");
pixbuf = gdk_pixbuf_new_from_xpm_data ((const char**)toolbar_item->pixmap);
pixmap = gtk_image_new_from_pixbuf(pixbuf);
insert_view = gtk_toolbar_append_element (GTK_TOOLBAR (tool_menu_title_menu),
}
}
-void construct_main_window(mainWindow * parent, WindowCreationData * win_creation_data,
+void construct_main_window(MainWindow * parent, WindowCreationData * win_creation_data,
gboolean first_window)
{
g_critical("construct_main_window()");
GtkWidget * new_window; /* New generated main window */
- mainWindow * new_m_window;/* New main window structure */
+ MainWindow * new_m_window;/* New main window structure */
GtkNotebook * notebook;
LttvIAttribute *attributes =
LTTV_IATTRIBUTE(g_object_new(LTTV_ATTRIBUTE_TYPE, NULL));
LttvAttributeValue value;
- new_m_window = g_new(mainWindow, 1);
+ new_m_window = g_new(MainWindow, 1);
// Add the object's information to the module's array
g_main_window_list = g_slist_append(g_main_window_list, new_m_window);
new_window = create_MWindow();
gtk_widget_show (new_window);
- new_m_window->Attributes = attributes;
+ new_m_window->attributes = attributes;
- new_m_window->Traceset_Info = g_new(TracesetInfo,1);
- new_m_window->Traceset_Info->path = NULL ;
+ new_m_window->traceset_info = g_new(TracesetInfo,1);
+ new_m_window->traceset_info->path = NULL ;
- new_m_window->Traceset_Info->before_traceset = lttv_hooks_new();
- new_m_window->Traceset_Info->after_traceset = lttv_hooks_new();
- new_m_window->Traceset_Info->before_trace = lttv_hooks_new();
- new_m_window->Traceset_Info->after_trace = lttv_hooks_new();
- new_m_window->Traceset_Info->before_tracefile = lttv_hooks_new();
- new_m_window->Traceset_Info->after_tracefile = lttv_hooks_new();
- new_m_window->Traceset_Info->before_event = lttv_hooks_new();
- new_m_window->Traceset_Info->after_event = lttv_hooks_new();
+ new_m_window->traceset_info->before_traceset = lttv_hooks_new();
+ new_m_window->traceset_info->after_traceset = lttv_hooks_new();
+ new_m_window->traceset_info->before_trace = lttv_hooks_new();
+ new_m_window->traceset_info->after_trace = lttv_hooks_new();
+ new_m_window->traceset_info->before_tracefile = lttv_hooks_new();
+ new_m_window->traceset_info->after_tracefile = lttv_hooks_new();
+ new_m_window->traceset_info->before_event = lttv_hooks_new();
+ new_m_window->traceset_info->after_event = lttv_hooks_new();
g_assert(lttv_iattribute_find_by_path(attributes, "hooks/traceset/before",
LTTV_POINTER, &value));
- *(value.v_pointer) = new_m_window->Traceset_Info->before_traceset;
+ *(value.v_pointer) = new_m_window->traceset_info->before_traceset;
g_assert(lttv_iattribute_find_by_path(attributes, "hooks/traceset/after",
LTTV_POINTER, &value));
- *(value.v_pointer) = new_m_window->Traceset_Info->after_traceset;
+ *(value.v_pointer) = new_m_window->traceset_info->after_traceset;
g_assert(lttv_iattribute_find_by_path(attributes, "hooks/trace/before",
LTTV_POINTER, &value));
- *(value.v_pointer) = new_m_window->Traceset_Info->before_trace;
+ *(value.v_pointer) = new_m_window->traceset_info->before_trace;
g_assert(lttv_iattribute_find_by_path(attributes, "hooks/trace/after",
LTTV_POINTER, &value));
- *(value.v_pointer) = new_m_window->Traceset_Info->after_trace;
+ *(value.v_pointer) = new_m_window->traceset_info->after_trace;
g_assert(lttv_iattribute_find_by_path(attributes, "hooks/tracefile/before",
LTTV_POINTER, &value));
- *(value.v_pointer) = new_m_window->Traceset_Info->before_tracefile;
+ *(value.v_pointer) = new_m_window->traceset_info->before_tracefile;
g_assert(lttv_iattribute_find_by_path(attributes, "hooks/tracefile/after",
LTTV_POINTER, &value));
- *(value.v_pointer) = new_m_window->Traceset_Info->after_tracefile;
+ *(value.v_pointer) = new_m_window->traceset_info->after_tracefile;
g_assert(lttv_iattribute_find_by_path(attributes, "hooks/event/before",
LTTV_POINTER, &value));
- *(value.v_pointer) = new_m_window->Traceset_Info->before_event;
+ *(value.v_pointer) = new_m_window->traceset_info->before_event;
g_assert(lttv_iattribute_find_by_path(attributes, "hooks/event/after",
LTTV_POINTER, &value));
- *(value.v_pointer) = new_m_window->Traceset_Info->after_event;
+ *(value.v_pointer) = new_m_window->traceset_info->after_event;
- new_m_window->MWindow = new_window;
- new_m_window->Tab = NULL;
- new_m_window->CurrentTab = NULL;
- new_m_window->Attributes = LTTV_IATTRIBUTE(g_object_new(LTTV_ATTRIBUTE_TYPE, NULL));
+ new_m_window->mwindow = new_window;
+ new_m_window->tab = NULL;
+ new_m_window->current_tab = NULL;
+ new_m_window->attributes = LTTV_IATTRIBUTE(g_object_new(LTTV_ATTRIBUTE_TYPE, NULL));
if(parent){
- new_m_window->Traceset_Info->traceset =
- lttv_traceset_copy(parent->Traceset_Info->traceset);
+ new_m_window->traceset_info->traceset =
+ lttv_traceset_copy(parent->traceset_info->traceset);
//FIXME copy not implemented in lower level
- new_m_window->Traceset_Info->TracesetContext =
+ new_m_window->traceset_info->traceset_context =
g_object_new(LTTV_TRACESET_STATS_TYPE, NULL);
lttv_context_init(
- LTTV_TRACESET_CONTEXT(new_m_window->Traceset_Info->TracesetContext),
- new_m_window->Traceset_Info->traceset);
+ LTTV_TRACESET_CONTEXT(new_m_window->traceset_info->traceset_context),
+ new_m_window->traceset_info->traceset);
//new_m_window->traceset_context = parent->traceset_context;
- new_m_window->winCreationData = parent->winCreationData;
+ new_m_window->win_creation_data = parent->win_creation_data;
}else{
- new_m_window->Traceset_Info->traceset = lttv_traceset_new();
+ new_m_window->traceset_info->traceset = lttv_traceset_new();
/* Add the command line trace */
if(g_init_trace != NULL && first_window)
- lttv_traceset_add(new_m_window->Traceset_Info->traceset, g_init_trace);
+ lttv_traceset_add(new_m_window->traceset_info->traceset, g_init_trace);
/* NOTE : the context must be recreated if we change the traceset,
* ie : adding/removing traces */
- new_m_window->Traceset_Info->TracesetContext =
+ new_m_window->traceset_info->traceset_context =
g_object_new(LTTV_TRACESET_STATS_TYPE, NULL);
lttv_context_init(
- LTTV_TRACESET_CONTEXT(new_m_window->Traceset_Info->TracesetContext),
- new_m_window->Traceset_Info->traceset);
+ LTTV_TRACESET_CONTEXT(new_m_window->traceset_info->traceset_context),
+ new_m_window->traceset_info->traceset);
- new_m_window->winCreationData = win_creation_data;
+ new_m_window->win_creation_data = win_creation_data;
}
new_m_window->hash_menu_item = g_hash_table_new_full (g_str_hash, g_str_equal,
g_object_set_data(G_OBJECT(new_window), "mainWindow", (gpointer)new_m_window);
//create a default tab
- notebook = (GtkNotebook *)lookup_widget(new_m_window->MWindow, "MNotebook");
+ notebook = (GtkNotebook *)lookup_widget(new_m_window->mwindow, "MNotebook");
if(notebook == NULL){
g_printf("Notebook does not exist\n");
return;
}
//for now there is no name field in LttvTraceset structure
//Use "Traceset" as the label for the default tab
- create_tab(new_m_window->MWindow, notebook,"Traceset");
+ create_tab(new_m_window->mwindow, notebook,"Traceset");
g_object_set_data_full(
- G_OBJECT(new_m_window->MWindow),
+ G_OBJECT(new_m_window->mwindow),
"Main_Window_Data",
new_m_window,
(GDestroyNotify)main_window_free);
g_win_count++;
}
-void tab_destructor(tab * tab_instance)
+void tab_destructor(Tab * tab_instance)
{
- if(tab_instance->Attributes)
- g_object_unref(tab_instance->Attributes);
+ if(tab_instance->attributes)
+ g_object_unref(tab_instance->attributes);
- if(tab_instance->mw->Tab == tab_instance){
- tab_instance->mw->Tab = tab_instance->Next;
+ if(tab_instance->mw->tab == tab_instance){
+ tab_instance->mw->tab = tab_instance->next;
}else{
- tab * tmp1, *tmp = tab_instance->mw->Tab;
+ Tab * tmp1, *tmp = tab_instance->mw->tab;
while(tmp != tab_instance){
tmp1 = tmp;
- tmp = tmp->Next;
+ tmp = tmp->next;
}
- tmp1->Next = tab_instance->Next;
+ tmp1->next = tab_instance->next;
}
g_free(tab_instance);
}
void * create_tab(GtkWidget* parent, GtkNotebook * notebook, char * label)
{
GList * list;
- tab * tmp_tab;
- mainWindow * mw_data;
+ Tab * tmp_tab;
+ MainWindow * mw_data;
LttTime tmp_time;
mw_data = get_window_data_struct(parent);
- tmp_tab = mw_data->Tab;
- while(tmp_tab && tmp_tab->Next) tmp_tab = tmp_tab->Next;
+ tmp_tab = mw_data->tab;
+ while(tmp_tab && tmp_tab->next) tmp_tab = tmp_tab->next;
if(!tmp_tab){
- mw_data->CurrentTab = NULL;
- tmp_tab = g_new(tab,1);
- mw_data->Tab = tmp_tab;
+ mw_data->current_tab = NULL;
+ tmp_tab = g_new(Tab,1);
+ mw_data->tab = tmp_tab;
}else{
- tmp_tab->Next = g_new(tab,1);
- tmp_tab = tmp_tab->Next;
+ tmp_tab->next = g_new(Tab,1);
+ tmp_tab = tmp_tab->next;
}
- if(mw_data->CurrentTab){
+ if(mw_data->current_tab){
// Will have to read directly at the main window level, as we want
// to be able to modify a traceset on the fly.
- // tmp_tab->traceStartTime = mw_data->CurrentTab->traceStartTime;
- // tmp_tab->traceEndTime = mw_data->CurrentTab->traceEndTime;
- tmp_tab->Time_Window = mw_data->CurrentTab->Time_Window;
- tmp_tab->currentTime = mw_data->CurrentTab->currentTime;
+ // tmp_tab->traceStartTime = mw_data->current_tab->traceStartTime;
+ // tmp_tab->traceEndTime = mw_data->current_tab->traceEndTime;
+ tmp_tab->time_window = mw_data->current_tab->time_window;
+ tmp_tab->current_time = mw_data->current_tab->current_time;
}else{
// Will have to read directly at the main window level, as we want
// to be able to modify a traceset on the fly.
// getTracesetTimeSpan(mw_data,&tmp_tab->traceStartTime, &tmp_tab->traceEndTime);
- tmp_tab->Time_Window.startTime =
- LTTV_TRACESET_CONTEXT(mw_data->Traceset_Info->TracesetContext)->Time_Span->startTime;
+ tmp_tab->time_window.start_time =
+ LTTV_TRACESET_CONTEXT(mw_data->traceset_info->traceset_context)->Time_Span->startTime;
if(DEFAULT_TIME_WIDTH_S <
- LTTV_TRACESET_CONTEXT(mw_data->Traceset_Info->TracesetContext)->Time_Span->endTime.tv_sec)
+ LTTV_TRACESET_CONTEXT(mw_data->traceset_info->traceset_context)->Time_Span->endTime.tv_sec)
tmp_time.tv_sec = DEFAULT_TIME_WIDTH_S;
else
tmp_time.tv_sec =
- LTTV_TRACESET_CONTEXT(mw_data->Traceset_Info->TracesetContext)->Time_Span->endTime.tv_sec;
+ LTTV_TRACESET_CONTEXT(mw_data->traceset_info->traceset_context)->Time_Span->endTime.tv_sec;
tmp_time.tv_nsec = 0;
- tmp_tab->Time_Window.Time_Width = tmp_time ;
- tmp_tab->currentTime.tv_sec = tmp_time.tv_sec / 2;
- tmp_tab->currentTime.tv_nsec = 0 ;
+ tmp_tab->time_window.time_width = tmp_time ;
+ tmp_tab->current_time.tv_sec = tmp_time.tv_sec / 2;
+ tmp_tab->current_time.tv_nsec = 0 ;
}
- tmp_tab->Attributes = LTTV_IATTRIBUTE(g_object_new(LTTV_ATTRIBUTE_TYPE, NULL));
- // mw_data->CurrentTab = tmp_tab;
+ tmp_tab->attributes = LTTV_IATTRIBUTE(g_object_new(LTTV_ATTRIBUTE_TYPE, NULL));
+ // mw_data->current_tab = tmp_tab;
tmp_tab->custom = (GtkCustom*)gtk_custom_new();
tmp_tab->custom->mw = mw_data;
gtk_widget_show((GtkWidget*)tmp_tab->custom);
- tmp_tab->Next = NULL;
+ tmp_tab->next = NULL;
tmp_tab->mw = mw_data;
tmp_tab->label = gtk_label_new (label);
void remove_menu_item(gpointer main_win, gpointer user_data)
{
- mainWindow * mw = (mainWindow *) main_win;
+ MainWindow * mw = (MainWindow *) main_win;
lttv_menu_closure *menu_item = (lttv_menu_closure *)user_data;
GtkWidget * tool_menu_title_menu, *insert_view;
- tool_menu_title_menu = lookup_widget(mw->MWindow,"ToolMenuTitle_menu");
+ tool_menu_title_menu = lookup_widget(mw->mwindow,"ToolMenuTitle_menu");
insert_view = (GtkWidget*)g_hash_table_lookup(mw->hash_menu_item,
menu_item->menuText);
if(insert_view){
void remove_toolbar_item(gpointer main_win, gpointer user_data)
{
- mainWindow * mw = (mainWindow *) main_win;
+ MainWindow * mw = (MainWindow *) main_win;
lttv_toolbar_closure *toolbar_item = (lttv_toolbar_closure *)user_data;
GtkWidget * tool_menu_title_menu, *insert_view;
- tool_menu_title_menu = lookup_widget(mw->MWindow,"MToolbar2");
+ tool_menu_title_menu = lookup_widget(mw->mwindow,"MToolbar2");
insert_view = (GtkWidget*)g_hash_table_lookup(mw->hash_toolbar_item,
toolbar_item->tooltip);
if(insert_view){
/* internal functions */
void create_new_window(GtkWidget* widget, gpointer user_data, gboolean clone);
-void insert_menu_toolbar_item(mainWindow * mw, gpointer user_data);
-void construct_main_window(mainWindow * parent, WindowCreationData *win_creation_data,
+void insert_menu_toolbar_item(MainWindow * mw, gpointer user_data);
+void construct_main_window(MainWindow * parent, WindowCreationData *win_creation_data,
gboolean first_window);
-void main_window_free(mainWindow * mw);
-void main_window_destructor(mainWindow * mw);
+void main_window_free(MainWindow * mw);
+void main_window_destructor(MainWindow * mw);
/* callback functions*/
GTK_WIDGET_SET_FLAGS (custom, GTK_NO_WINDOW);
gtk_widget_set_redraw_on_allocate (GTK_WIDGET (custom), FALSE);
- custom->firstPane = NULL;
- custom->lastPane = NULL;
- custom->focusedPane = NULL;
- custom->numChildren = 0;
+ custom->first_pane = NULL;
+ custom->last_pane = NULL;
+ custom->focused_pane = NULL;
+ custom->num_children = 0;
custom->vbox = NULL;
// custom->scrollWindow = NULL;
// custom->viewport = NULL;
- custom->hScrollbar = NULL;
+ custom->hscrollbar = NULL;
}
{
GtkCustom * custom = (GtkCustom*) widget;
GtkPaned * pane;
- if(!custom->firstPane) return;
+ if(!custom->first_pane) return;
- pane = custom->firstPane;
+ pane = custom->first_pane;
while(1){
if((GtkWidget*)pane == (GtkWidget*)user_data){
- custom->focusedPane = pane;
+ custom->focused_pane = pane;
break;
}
- if(pane == custom->lastPane){
- custom->focusedPane = NULL;
+ if(pane == custom->last_pane){
+ custom->focused_pane = NULL;
break;
}
pane = (GtkPaned*)pane->child1;
g_object_ref(G_OBJECT(widget1));
- if(!custom->firstPane){
- custom->firstPane = (GtkPaned *)gtk_vpaned_new();
- custom->lastPane = custom->firstPane;
+ if(!custom->first_pane){
+ custom->first_pane = (GtkPaned *)gtk_vpaned_new();
+ custom->last_pane = custom->first_pane;
- custom->hScrollbar = gtk_hscrollbar_new (NULL);
- gtk_widget_show(custom->hScrollbar);
+ custom->hscrollbar = gtk_hscrollbar_new (NULL);
+ gtk_widget_show(custom->hscrollbar);
- custom->hAdjust = gtk_range_get_adjustment(GTK_RANGE(custom->hScrollbar));
+ custom->hadjust = gtk_range_get_adjustment(GTK_RANGE(custom->hscrollbar));
GetTimeWindow(custom->mw,&Time_Window);
GetCurrentTime(custom->mw,&time);
- Time_Span = LTTV_TRACESET_CONTEXT(custom->mw->Traceset_Info->TracesetContext)->Time_Span ;
+ Time_Span = LTTV_TRACESET_CONTEXT(custom->mw->traceset_info->traceset_context)->Time_Span ;
- custom->hAdjust->lower = ltt_time_to_double(Time_Span->startTime) *
+ custom->hadjust->lower = ltt_time_to_double(Time_Span->startTime) *
NANOSECONDS_PER_SECOND;
- custom->hAdjust->value = custom->hAdjust->lower;
- custom->hAdjust->upper = ltt_time_to_double(Time_Span->endTime) *
+ custom->hadjust->value = custom->hadjust->lower;
+ custom->hadjust->upper = ltt_time_to_double(Time_Span->endTime) *
NANOSECONDS_PER_SECOND;
/* Page increment of whole visible area */
- custom->hAdjust->page_increment = ltt_time_to_double(
- Time_Window.Time_Width) * NANOSECONDS_PER_SECOND;
+ custom->hadjust->page_increment = ltt_time_to_double(
+ Time_Window.time_width) * NANOSECONDS_PER_SECOND;
/* page_size to the whole visible area will take care that the
* scroll value + the shown area will never be more than what is
* in the trace. */
- custom->hAdjust->page_size = custom->hAdjust->page_increment;
- custom->hAdjust->step_increment = custom->hAdjust->page_increment / 10;
+ custom->hadjust->page_size = custom->hadjust->page_increment;
+ custom->hadjust->step_increment = custom->hadjust->page_increment / 10;
- gtk_range_set_update_policy (GTK_RANGE(custom->hScrollbar),
+ gtk_range_set_update_policy (GTK_RANGE(custom->hscrollbar),
GTK_UPDATE_DISCONTINUOUS);
- g_signal_connect(G_OBJECT(custom->hScrollbar), "value-changed",
+ g_signal_connect(G_OBJECT(custom->hscrollbar), "value-changed",
G_CALLBACK(gtk_custom_scroll_value_changed), custom);
custom->vbox = gtk_vbox_new(FALSE,0);
// gtk_widget_show(custom->viewport);
// gtk_container_add(GTK_CONTAINER(custom->viewport), (GtkWidget*)custom->vbox);
- gtk_box_pack_end(GTK_BOX(custom->vbox),(GtkWidget*)custom->hScrollbar,FALSE,FALSE,0);
- gtk_box_pack_end(GTK_BOX(custom->vbox),(GtkWidget*)custom->firstPane,TRUE,TRUE,0);
+ gtk_box_pack_end(GTK_BOX(custom->vbox),(GtkWidget*)custom->hscrollbar,FALSE,FALSE,0);
+ gtk_box_pack_end(GTK_BOX(custom->vbox),(GtkWidget*)custom->first_pane,TRUE,TRUE,0);
// custom->scrollWindow = gtk_scrolled_window_new (NULL, NULL);
// gtk_widget_show(custom->scrollWindow);
gtk_paned_pack1(GTK_PANED(custom), (GtkWidget*)custom->vbox,FALSE, TRUE);
}else{
- tmpPane = custom->lastPane;
- custom->lastPane = (GtkPaned *)gtk_vpaned_new();
- gtk_paned_pack1 (tmpPane,(GtkWidget*)custom->lastPane, FALSE,TRUE);
+ tmpPane = custom->last_pane;
+ custom->last_pane = (GtkPaned *)gtk_vpaned_new();
+ gtk_paned_pack1 (tmpPane,(GtkWidget*)custom->last_pane, FALSE,TRUE);
}
- gtk_widget_show((GtkWidget *)custom->lastPane);
+ gtk_widget_show((GtkWidget *)custom->last_pane);
- gtk_paned_pack2 (custom->lastPane,widget1, TRUE, TRUE);
- custom->focusedPane = custom->lastPane;
- custom->numChildren++;
+ gtk_paned_pack2 (custom->last_pane,widget1, TRUE, TRUE);
+ custom->focused_pane = custom->last_pane;
+ custom->num_children++;
}
{
GtkPaned * tmp, *prev, *next;
- if(!custom->focusedPane) return;
+ if(!custom->focused_pane) return;
- tmp = (GtkPaned*)custom->focusedPane->child2; //widget in vpaned
+ tmp = (GtkPaned*)custom->focused_pane->child2; //widget in vpaned
g_object_unref(G_OBJECT(tmp));
- if(custom->focusedPane == custom->firstPane &&
- custom->focusedPane == custom->lastPane){
+ if(custom->focused_pane == custom->first_pane &&
+ custom->focused_pane == custom->last_pane){
// gtk_container_remove(GTK_CONTAINER(custom),(GtkWidget*)custom->scrollWindow);
gtk_container_remove(GTK_CONTAINER(custom),(GtkWidget*)custom->vbox);
- custom->firstPane = NULL;
- custom->lastPane = NULL;
- custom->focusedPane = NULL;
- }else if(custom->focusedPane == custom->firstPane &&
- custom->focusedPane != custom->lastPane){
- next = (GtkPaned*)custom->firstPane->child1;
+ custom->first_pane = NULL;
+ custom->last_pane = NULL;
+ custom->focused_pane = NULL;
+ }else if(custom->focused_pane == custom->first_pane &&
+ custom->focused_pane != custom->last_pane){
+ next = (GtkPaned*)custom->first_pane->child1;
g_object_ref(G_OBJECT(next));
- gtk_container_remove(GTK_CONTAINER(custom->firstPane),(GtkWidget*)next);
- gtk_container_remove(GTK_CONTAINER(custom->vbox),(GtkWidget*)custom->firstPane);
- custom->firstPane = next;
- gtk_box_pack_end(GTK_BOX(custom->vbox),(GtkWidget*)custom->firstPane,TRUE,TRUE,0);
- custom->focusedPane = custom->firstPane;
+ gtk_container_remove(GTK_CONTAINER(custom->first_pane),(GtkWidget*)next);
+ gtk_container_remove(GTK_CONTAINER(custom->vbox),(GtkWidget*)custom->first_pane);
+ custom->first_pane = next;
+ gtk_box_pack_end(GTK_BOX(custom->vbox),(GtkWidget*)custom->first_pane,TRUE,TRUE,0);
+ custom->focused_pane = custom->first_pane;
g_object_unref(G_OBJECT(next));
- }else if(custom->focusedPane != custom->firstPane &&
- custom->focusedPane == custom->lastPane){
- tmp = custom->lastPane;
- custom->lastPane = (GtkPaned*)gtk_widget_get_parent((GtkWidget*)custom->lastPane);
- custom->focusedPane = custom->lastPane;
- gtk_container_remove(GTK_CONTAINER(custom->lastPane),(GtkWidget*)tmp);
+ }else if(custom->focused_pane != custom->first_pane &&
+ custom->focused_pane == custom->last_pane){
+ tmp = custom->last_pane;
+ custom->last_pane = (GtkPaned*)gtk_widget_get_parent((GtkWidget*)custom->last_pane);
+ custom->focused_pane = custom->last_pane;
+ gtk_container_remove(GTK_CONTAINER(custom->last_pane),(GtkWidget*)tmp);
}else{
- tmp = custom->focusedPane;
+ tmp = custom->focused_pane;
prev = (GtkPaned*)gtk_widget_get_parent((GtkWidget*)tmp);
next = (GtkPaned*)tmp->child1;
g_object_ref(G_OBJECT(next));
- gtk_container_remove(GTK_CONTAINER(custom->focusedPane),(GtkWidget*)next);
- gtk_container_remove(GTK_CONTAINER(prev),(GtkWidget*)custom->focusedPane);
+ gtk_container_remove(GTK_CONTAINER(custom->focused_pane),(GtkWidget*)next);
+ gtk_container_remove(GTK_CONTAINER(prev),(GtkWidget*)custom->focused_pane);
gtk_paned_pack1(prev, (GtkWidget*)next, FALSE, TRUE);
- custom->focusedPane = next;
+ custom->focused_pane = next;
g_object_unref(G_OBJECT(next));
}
- custom->numChildren--;
+ custom->num_children--;
}
GtkWidget* upWidget, *downWidget;
GtkPaned * prev,*next, *prevPrev;
- if(custom->lastPane == custom->focusedPane) return;
+ if(custom->last_pane == custom->focused_pane) return;
// move VPane
- prev = (GtkPaned*)custom->focusedPane->child1;
+ prev = (GtkPaned*)custom->focused_pane->child1;
g_object_ref(G_OBJECT(prev));
- gtk_container_remove(GTK_CONTAINER(custom->focusedPane),(GtkWidget*)prev);
+ gtk_container_remove(GTK_CONTAINER(custom->focused_pane),(GtkWidget*)prev);
- if(prev == custom->lastPane){
+ if(prev == custom->last_pane){
prevPrev = NULL;
- custom->lastPane = custom->focusedPane;
+ custom->last_pane = custom->focused_pane;
}else{
prevPrev = (GtkPaned*)prev->child1;
g_object_ref(G_OBJECT(prevPrev));
gtk_container_remove(GTK_CONTAINER(prev),(GtkWidget*)prevPrev);
}
- g_object_ref(G_OBJECT(custom->focusedPane));
- if(custom->firstPane == custom->focusedPane){
- gtk_container_remove(GTK_CONTAINER(custom->vbox),(GtkWidget*)custom->focusedPane);
+ g_object_ref(G_OBJECT(custom->focused_pane));
+ if(custom->first_pane == custom->focused_pane){
+ gtk_container_remove(GTK_CONTAINER(custom->vbox),(GtkWidget*)custom->focused_pane);
gtk_box_pack_end(GTK_BOX(custom->vbox),(GtkWidget*)prev,TRUE,TRUE,0);
- custom->firstPane = prev;
+ custom->first_pane = prev;
}else{
- next = (GtkPaned*)gtk_widget_get_parent((GtkWidget*)custom->focusedPane);
- gtk_container_remove(GTK_CONTAINER(next),(GtkWidget*)custom->focusedPane);
+ next = (GtkPaned*)gtk_widget_get_parent((GtkWidget*)custom->focused_pane);
+ gtk_container_remove(GTK_CONTAINER(next),(GtkWidget*)custom->focused_pane);
gtk_paned_pack1(GTK_PANED(next), (GtkWidget*)prev, FALSE,TRUE);
}
- gtk_paned_pack1(GTK_PANED(prev),(GtkWidget*)custom->focusedPane, FALSE,TRUE);
+ gtk_paned_pack1(GTK_PANED(prev),(GtkWidget*)custom->focused_pane, FALSE,TRUE);
if(prevPrev)
- gtk_paned_pack1(GTK_PANED(custom->focusedPane),(GtkWidget*)prevPrev, FALSE,TRUE);
+ gtk_paned_pack1(GTK_PANED(custom->focused_pane),(GtkWidget*)prevPrev, FALSE,TRUE);
g_object_unref(G_OBJECT(prev));
if(prevPrev) g_object_unref(G_OBJECT(prevPrev));
- g_object_unref(G_OBJECT(custom->focusedPane));
+ g_object_unref(G_OBJECT(custom->focused_pane));
}
GtkWidget* upWidget, *downWidget;
GtkPaned * prev,*next, *nextNext;
- if(custom->firstPane == custom->focusedPane) return;
+ if(custom->first_pane == custom->focused_pane) return;
//move VPane
- next = (GtkPaned*)gtk_widget_get_parent((GtkWidget*)custom->focusedPane);
+ next = (GtkPaned*)gtk_widget_get_parent((GtkWidget*)custom->focused_pane);
g_object_ref(G_OBJECT(next));
- if(custom->lastPane == custom->focusedPane){
+ if(custom->last_pane == custom->focused_pane){
prev = NULL;
- custom->lastPane = next;
+ custom->last_pane = next;
}else{
- prev = (GtkPaned*)custom->focusedPane->child1;
+ prev = (GtkPaned*)custom->focused_pane->child1;
g_object_ref(G_OBJECT(prev));
- gtk_container_remove(GTK_CONTAINER(custom->focusedPane),(GtkWidget*)prev);
+ gtk_container_remove(GTK_CONTAINER(custom->focused_pane),(GtkWidget*)prev);
}
- g_object_ref(G_OBJECT(custom->focusedPane));
- gtk_container_remove(GTK_CONTAINER(next),(GtkWidget*)custom->focusedPane);
+ g_object_ref(G_OBJECT(custom->focused_pane));
+ gtk_container_remove(GTK_CONTAINER(next),(GtkWidget*)custom->focused_pane);
- if(next == custom->firstPane){
- custom->firstPane = custom->focusedPane;
+ if(next == custom->first_pane){
+ custom->first_pane = custom->focused_pane;
gtk_container_remove(GTK_CONTAINER(custom->vbox),(GtkWidget*)next);
- gtk_box_pack_end(GTK_BOX(custom->vbox),(GtkWidget*)custom->focusedPane,TRUE,TRUE,0);
+ gtk_box_pack_end(GTK_BOX(custom->vbox),(GtkWidget*)custom->focused_pane,TRUE,TRUE,0);
}else{
nextNext = (GtkPaned*)gtk_widget_get_parent((GtkWidget*)next);
gtk_container_remove(GTK_CONTAINER(nextNext),(GtkWidget*)next);
- gtk_paned_pack1(nextNext, (GtkWidget*)custom->focusedPane, FALSE, TRUE);
+ gtk_paned_pack1(nextNext, (GtkWidget*)custom->focused_pane, FALSE, TRUE);
}
- gtk_paned_pack1(custom->focusedPane,(GtkWidget*)next, FALSE,TRUE);
+ gtk_paned_pack1(custom->focused_pane,(GtkWidget*)next, FALSE,TRUE);
if(prev)
gtk_paned_pack1(next,(GtkWidget*)prev, FALSE,TRUE);
if(prev)g_object_unref(G_OBJECT(prev));
g_object_unref(G_OBJECT(next));
- g_object_unref(G_OBJECT(custom->focusedPane));
+ g_object_unref(G_OBJECT(custom->focused_pane));
}
void gtk_custom_scroll_value_changed(GtkRange *range, gpointer custom_arg)
#include "callbacks.h"
/* global variable */
-//LttvTracesetStats * gTracesetContext = NULL;
-//static LttvTraceset * traceset;
static WindowCreationData win_creation_data;
/** Array containing instanced objects. */
}
void
-main_window_free(mainWindow * mw)
+main_window_free(MainWindow * mw)
{
guint i, nb, ref_count;
LttvTrace * trace;
if(mw){
g_critical("begin remove");
- lttv_hooks_destroy(mw->Traceset_Info->before_traceset);
- lttv_hooks_destroy(mw->Traceset_Info->after_traceset);
- lttv_hooks_destroy(mw->Traceset_Info->before_trace);
- lttv_hooks_destroy(mw->Traceset_Info->after_trace);
- lttv_hooks_destroy(mw->Traceset_Info->before_tracefile);
- lttv_hooks_destroy(mw->Traceset_Info->after_tracefile);
- lttv_hooks_destroy(mw->Traceset_Info->before_event);
- lttv_hooks_destroy(mw->Traceset_Info->after_event);
+ lttv_hooks_destroy(mw->traceset_info->before_traceset);
+ lttv_hooks_destroy(mw->traceset_info->after_traceset);
+ lttv_hooks_destroy(mw->traceset_info->before_trace);
+ lttv_hooks_destroy(mw->traceset_info->after_trace);
+ lttv_hooks_destroy(mw->traceset_info->before_tracefile);
+ lttv_hooks_destroy(mw->traceset_info->after_tracefile);
+ lttv_hooks_destroy(mw->traceset_info->before_event);
+ lttv_hooks_destroy(mw->traceset_info->after_event);
g_critical("end remove");
- if(mw->Traceset_Info->path != NULL)
- g_free(mw->Traceset_Info->path);
- if(mw->Traceset_Info->TracesetContext != NULL){
- lttv_context_fini(LTTV_TRACESET_CONTEXT(mw->Traceset_Info->TracesetContext));
- g_object_unref(mw->Traceset_Info->TracesetContext);
+ if(mw->traceset_info->path != NULL)
+ g_free(mw->traceset_info->path);
+ if(mw->traceset_info->traceset_context != NULL){
+ lttv_context_fini(LTTV_TRACESET_CONTEXT(mw->traceset_info->traceset_context));
+ g_object_unref(mw->traceset_info->traceset_context);
}
- if(mw->Traceset_Info->traceset != NULL) {
- nb = lttv_traceset_number(mw->Traceset_Info->traceset);
+ if(mw->traceset_info->traceset != NULL) {
+ nb = lttv_traceset_number(mw->traceset_info->traceset);
for(i = 0 ; i < nb ; i++) {
- trace = lttv_traceset_get(mw->Traceset_Info->traceset, i);
+ trace = lttv_traceset_get(mw->traceset_info->traceset, i);
ref_count = lttv_trace_get_ref_number(trace);
if(ref_count <= 1)
ltt_trace_close(lttv_trace(trace));
}
}
- lttv_traceset_destroy(mw->Traceset_Info->traceset);
+ lttv_traceset_destroy(mw->traceset_info->traceset);
- g_object_unref(mw->Attributes);
+ g_object_unref(mw->attributes);
- g_free(mw->Traceset_Info);
- mw->Traceset_Info = NULL;
+ g_free(mw->traceset_info);
+ mw->traceset_info = NULL;
g_main_window_list = g_slist_remove(g_main_window_list, mw);
}
void
-main_window_destructor(mainWindow * mw)
+main_window_destructor(MainWindow * mw)
{
- if(GTK_IS_WIDGET(mw->MWindow)){
- gtk_widget_destroy(mw->MWindow);
+ if(GTK_IS_WIDGET(mw->mwindow)){
+ gtk_widget_destroy(mw->mwindow);
// gtk_widget_destroy(mw->HelpContents);
// gtk_widget_destroy(mw->AboutBox);
mw = NULL;
void main_window_destroy_walk(gpointer data, gpointer user_data)
{
- main_window_destructor((mainWindow*)data);
+ main_window_destructor((MainWindow*)data);
}
* @return The widget created.
*/
GtkWidget *
-hGuiControlFlow(mainWindow *pmParentWindow)
+hGuiControlFlow(MainWindow *pmParentWindow)
{
g_critical("hGuiControlFlow");
ControlFlowData *Control_Flow_Data = GuiControlFlow() ;
*Time_Window = *New_Time_Window;
g_critical("New time window HOOK : %u, %u to %u, %u",
- Time_Window->startTime.tv_sec,
- Time_Window->startTime.tv_nsec,
- Time_Window->Time_Width.tv_sec,
- Time_Window->Time_Width.tv_nsec);
+ Time_Window->start_time.tv_sec,
+ Time_Window->start_time.tv_nsec,
+ Time_Window->time_width.tv_sec,
+ Time_Window->time_width.tv_nsec);
Drawing_Data_Request(Control_Flow_Data->Drawing,
&Control_Flow_Data->Drawing->Pixmap,
void send_test_data(ProcessList *Process_List, Drawing_t *Drawing);
-GtkWidget *hGuiControlFlow(mainWindow *pmParentWindow);
+GtkWidget *hGuiControlFlow(MainWindow *pmParentWindow);
int Event_Selected_Hook(void *hook_data, void *call_data);
typedef struct _EventViewerData {
- mainWindow * mw;
+ MainWindow * mw;
TimeWindow time_window;
LttTime current_time;
LttvHooks * before_event_hooks;
} EventViewerData ;
//! Event Viewer's constructor hook
-GtkWidget *h_gui_events(mainWindow *parent_window);
+GtkWidget *h_gui_events(MainWindow *parent_window);
//! Event Viewer's constructor
-EventViewerData *gui_events(mainWindow *parent_window);
+EventViewerData *gui_events(MainWindow *parent_window);
//! Event Viewer's destructor
void gui_events_destructor(EventViewerData *event_viewer_data);
void gui_events_free(EventViewerData *event_viewer_data);
* @return The widget created.
*/
GtkWidget *
-h_gui_events(mainWindow * parent_window)
+h_gui_events(MainWindow * parent_window)
{
EventViewerData* event_viewer_data = gui_events(parent_window) ;
* @return The Event viewer data created.
*/
EventViewerData *
-gui_events(mainWindow *parent_window)
+gui_events(MainWindow *parent_window)
{
LttTime start, end;
GtkTreeViewColumn *column;
void tree_v_grab_focus(GtkWidget *widget, gpointer data){
EventViewerData *event_viewer_data = (EventViewerData *)data;
- mainWindow * mw = event_viewer_data->mw;
+ MainWindow * mw = event_viewer_data->mw;
SetFocusedPane(mw, gtk_widget_get_parent(event_viewer_data->hbox_v));
}
typedef struct _StatisticViewerData StatisticViewerData;
//! Statistic Viewer's constructor hook
-GtkWidget *h_gui_statistic(mainWindow *parent_window);
+GtkWidget *h_gui_statistic(MainWindow *parent_window);
//! Statistic Viewer's constructor
-StatisticViewerData *gui_statistic(mainWindow *parent_window);
+StatisticViewerData *gui_statistic(MainWindow *parent_window);
//! Statistic Viewer's destructor
void gui_statistic_destructor(StatisticViewerData *statistic_viewer_data);
void gui_statistic_free(StatisticViewerData *statistic_viewer_data);
};
struct _StatisticViewerData{
- mainWindow * mw;
+ MainWindow * mw;
LttvTracesetStats * stats;
GtkWidget * hpaned_v;
* @return The widget created.
*/
GtkWidget *
-h_gui_statistic(mainWindow * parent_window)
+h_gui_statistic(MainWindow * parent_window)
{
StatisticViewerData* statistic_viewer_data = gui_statistic(parent_window) ;
* @return The Statistic viewer data created.
*/
StatisticViewerData *
-gui_statistic(mainWindow *parent_window)
+gui_statistic(MainWindow *parent_window)
{
GtkCellRenderer *renderer;
GtkTreeViewColumn *column;
void grab_focus(GtkWidget *widget, gpointer data)
{
StatisticViewerData *statistic_viewer_data = (StatisticViewerData *)data;
- mainWindow * mw = statistic_viewer_data->mw;
+ MainWindow * mw = statistic_viewer_data->mw;
SetFocusedPane(mw, gtk_widget_get_parent(statistic_viewer_data->hpaned_v));
}