X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=ltt%2Fbranches%2Fpoly%2Flttv%2Fmodules%2Fgui%2Flttvwindow%2Flttvwindow%2Flttvwindow.h;h=a3867f0287bb78ce5a718bedd871f66fef947424;hb=efcd775db82bb1fec940c8e3cc8dd00b8de794a0;hp=4b856245a6f41c4d24a3d8731ee2751425d87610;hpb=088f6772c700cf75d4ba27adf086dc37d961a960;p=lttv.git diff --git a/ltt/branches/poly/lttv/modules/gui/lttvwindow/lttvwindow/lttvwindow.h b/ltt/branches/poly/lttv/modules/gui/lttvwindow/lttvwindow/lttvwindow.h index 4b856245..a3867f02 100644 --- a/ltt/branches/poly/lttv/modules/gui/lttvwindow/lttvwindow/lttvwindow.h +++ b/ltt/branches/poly/lttv/modules/gui/lttvwindow/lttvwindow/lttvwindow.h @@ -239,8 +239,8 @@ FIXME : explain other important events */ -#ifndef VIEWER_H -#define VIEWER_H +#ifndef LTTVWINDOW_H +#define LTTVWINDOW_H /*! \file lttvwindow.h * \brief API used by the graphical viewers to interact with their top window. @@ -486,6 +486,18 @@ void lttvwindow_unregister_filter_notify(Tab *tab, gpointer hook_data); +/** + * Function to get the current filter of the main window : useful at viewer + * instanciation. + * + * @param tab the tab the viewer belongs to. + * + * returns : the current filter. + */ + + +LttvFilter *lttvwindow_get_filter(Tab *tab); + /** * Function to register a hook function for a viewer to set/update its * current time. @@ -516,6 +528,37 @@ void lttvwindow_unregister_current_time_notify(Tab *tab, LttvHook hook, gpointer hook_data); +/** + * Function to register a hook function for a viewer to set/update its + * current position. + * + * @param tab the tab the viewer belongs to. + * @param hook hook function of the viewer that updates the current time. The + * call_data is a LttTime* representing the new current time. + * @param hook_data hook data associated with the hook function. It will + * be typically a pointer to the viewer's data structure. + */ + +void lttvwindow_register_current_position_notify(Tab *tab, + LttvHook hook, + gpointer hook_data); + + +/** + * Function to unregister a viewer's hook function which is used to + * set/update the current position of the viewer. + * @param tab the tab the viewer belongs to. + * @param hook hook function of the viewer that updates the current time. The + * call_data is a LttTime* representing the new current time. + * @param hook_data hook data associated with the hook function. It will + * be typically a pointer to the viewer's data structure. + */ + +void lttvwindow_unregister_current_position_notify(Tab *tab, + LttvHook hook, + gpointer hook_data); + + /** * Function to register a hook function for a viewer to set/update the @@ -566,17 +609,28 @@ void lttvwindow_report_time_window(Tab *tab, TimeWindow time_window); /** - * Function to set the current time/event of the current tab. + * Function to set the current time of the current tab. * It will be called by a viewer's signal handle associated with * the button-release-event signal * @param tab the tab the viewer belongs to. - * @param new current time. + * @param time current time. */ void lttvwindow_report_current_time(Tab *tab, LttTime time); +/** + * Function to set the current event of the current tab. + * It will be called by a viewer's signal handle associated with + * the button-release-event signal + * @param tab the tab the viewer belongs to. + * @param pos the current position. + */ + +void lttvwindow_report_current_position(Tab *tab, + LttvTracesetContextPosition *pos); + /** * Function to set the position of the hpane's dividor (viewer). * It will typically be called by a viewer's signal handle associated @@ -657,6 +711,22 @@ void lttvwindow_events_request_remove_all(Tab *tab, gconstpointer viewer); +/** + * Function to see if there are events request pending. + * + * It tells if events requests are pending. Useful for checks in some events, + * i.e. detailed event list scrolling. + * + * @param tab the tab the viewer belongs to. + * @param viewer a pointer to the viewer data structure + * @return : TRUE is events requests are pending, else FALSE. + */ + +gboolean lttvwindow_events_request_pending(Tab *tab); + + + + /** * Function to get the current time interval shown on the current tab. * It will be called by a viewer's hook function to update the @@ -685,7 +755,7 @@ LttTime lttvwindow_get_current_time(Tab *tab); * @param filter, a pointer to a filter. */ -LttvFilter *lttvwindow_get_filter(Tab *tab); +//LttvFilter *lttvwindow_get_filter(Tab *tab); /** * Function to set the filter of the current tab. @@ -750,4 +820,8 @@ void set_time_window(Tab *tab, const TimeWindow *time_window); void set_current_time(Tab *tab, const LttTime *current_time); -#endif //VIEWER_H +void events_request_free(EventsRequest *events_request); + +GtkWidget *main_window_get_widget(Tab *tab); + +#endif //LTTVWINDOW_H