+++ /dev/null
-/*****************************************************************************
- * Callbacks used for the viewer *
- *****************************************************************************/
-void expose_event_cb (GtkWidget *widget, GdkEventExpose *expose, gpointer data)
-{
- ControlFlowData *control_flow_data = (ControlFlowData*)data;
-
- EventRequest *event_request = g_new(sizeof(EventRequest));
-
- event_request->control_flow_data = control_flow_data;
-
- /* Calculate, from pixels in expose, the time interval to get data */
-
- get_time_from_pixels(expose->area.x, expose->area.width,
- control_flow_data->drawing_Area_Info.width,
- &control_flow_data->Begin_Time, &control_flow_data->End_Time,
- &event_request->time_begin, &event_request->time_end)
-
- /* Look in statistics of the trace the processes present during the
- * whole time interval _shown on the screen_. Modify the list of
- * processes to match it. NOTE : modify, not recreate. If recreation is
- * needed,keep a pointer to the currently selected event in the list.
- */
-
- /* Call the reading API to have events sent to drawing hooks */
- lttv_trace_set_process( control_flow_data->Trace_Set,
- Draw_Before_Hooks,
- Draw_Event_Hooks,
- Draw_After_Hooks,
- NULL, //FIXME : filter here
- event_request->time_begin,
- event_request->time_end);
-
-}
-
-
-void v_scroll_cb (GtkAdjustment *adjustment, gpointer data)
-{
- ControlFlowData *control_flow_data = (ControlFlowData*)data;
- GtkTreePath *Tree_Path;
-
- g_critical("DEBUG : scroll signal, value : %f", adjustment->value);
-
- //get_test_data((int)adjustment->value, control_flow_data->Num_Visible_Events,
- // control_flow_data);
-
-
-
-}
-
-
+++ /dev/null
-//FIXME by including ltt.h
-#include <time.h>
-typedef time_t ltt_time;
-
-typedef struct _ltt_time_interval
-{
- ltt_time time_begin, time_end;
-} ltt_time_interval;
-
-// ???
-
-
- /* Setup the hooks */
- Draw_Before_Hooks = lttv_hooks_new();
- Draw_Event_Hooks = lttv_hooks_new();
- Draw_After_Hooks = lttv_hooks_new();
-
- lttv_hooks_add(Draw_Before_Hooks, Draw_Before_Hook, NULL);
- lttv_hooks_add(Draw_Event_Hooks, Draw_Event_Hook, NULL);
- lttv_hooks_add(Draw_After_Hooks, Draw_After_Hook, NULL);
-
- /* Destroy the hooks */
-
- lttv_hooks_destroy(Draw_Before_Hooks);
- lttv_hooks_destroy(Draw_Event_Hooks);
- lttv_hooks_destroy(Draw_After_Hooks);
-
-
-
-
-/*****************************************************************************
- * Definition of structures *
- *****************************************************************************/
-
-/* Structure used to store and use information relative to one events refresh
- * request. Typically filled in by the expose event callback, then passed to the
- * library call, then used by the drawing hooks. Then, once all the events are
- * sent, it is freed by the hook called after the reading.
- */
-typedef struct _EventRequest
-{
- ControlFlowData *control_flow_data;
- ltt_time time_begin, time_end;
- /* Fill the Events_Context during the initial expose, before calling for
- * events.
- */
- GArray Events_Context; //FIXME
-} EventRequest ;
-
-
-
-/*****************************************************************************
- * Function prototypes *
- *****************************************************************************/
-//! Control Flow Viewer's constructor hook
-GtkWidget *hGuiControlFlow(GtkWidget *mw);
-//! Control Flow Viewer's constructor
-ControlFlowData *GuiControlFlow(void);
-//! Control Flow Viewer's destructor
-void GuiControlFlow_Destructor(ControlFlowData *control_flow_data);
-
-
-static int Event_Selected_Hook(void *hook_data, void *call_data);
-
-static lttv_hooks
- *Draw_Before_Hooks,
- *Draw_Event_Hooks,
- *Draw_After_Hooks;
-
-Draw_Before_Hook(void *hook_data, void *call_data)
-Draw_Event_Hook(void *hook_data, void *call_data)
-Draw_After_Hook(void *hook_data, void *call_data)
-
-
-//void Tree_V_set_cursor(ControlFlowData *control_flow_data);
-//void Tree_V_get_cursor(ControlFlowData *control_flow_data);
-
-/* Prototype for selection handler callback */
-//static void tree_selection_changed_cb (GtkTreeSelection *selection, gpointer data);
-static void v_scroll_cb (GtkAdjustment *adjustment, gpointer data);
-//static void Tree_V_size_allocate_cb (GtkWidget *widget, GtkAllocation *alloc, gpointer data);
-//static void Tree_V_size_request_cb (GtkWidget *widget, GtkRequisition *requisition, gpointer data);
-//static void Tree_V_cursor_changed_cb (GtkWidget *widget, gpointer data);
-//static void Tree_V_move_cursor_cb (GtkWidget *widget, GtkMovementStep arg1, gint arg2, gpointer data);
-
-static void expose_event_cb (GtkWidget *widget, GdkEventExpose *expose, gpointer data);
-
-void add_test_process(ControlFlowData *control_flow_data);
-
-static void get_test_data(guint event_number, guint List_Height,
- ControlFlowData *control_flow_data);
-
-void add_test_data(ControlFlowData *control_flow_data);
-void test_draw(ControlFlowData *control_flow_data);
-
-void drawing_Area_Init(ControlFlowData *control_flow_data);
-
-
-/*\@}*/