#include <gtk/gtk.h>
#include <gdk/gdk.h>
-#include <lttv/processTrace.h>
-#include <lttv/gtktraceset.h>
+#include <lttv/lttv.h>
+#include <lttv/tracecontext.h>
+#include <lttvwindow/gtktraceset.h>
#include <lttv/hook.h>
#include "drawing.h"
LttTime window_end = ltt_time_add(control_flow_data->time_window.time_width,
control_flow_data->time_window.start_time);
- g_critical("req : window_end : %u, %u", window_end.tv_sec,
+ g_debug("req : window_end : %u, %u", window_end.tv_sec,
window_end.tv_nsec);
- g_critical("req : time width : %u, %u", control_flow_data->time_window.time_width.tv_sec,
+ g_debug("req : time width : %u, %u", control_flow_data->time_window.time_width.tv_sec,
control_flow_data->time_window.time_width.tv_nsec);
- g_critical("x is : %i, x+width is : %i", x, x+width);
+ g_debug("x is : %i, x+width is : %i", x, x+width);
convert_pixels_to_time(drawing->drawing_area->allocation.width, x,
&control_flow_data->time_window.start_time,
LttvTracesetContext * tsc =
get_traceset_context(control_flow_data->mw);
LttvTracesetState * tss =
- LTTV_TRACESET_STATE(tsc);
+ (LttvTracesetState*)tsc;
//send_test_process(
//guicontrolflow_get_process_list(drawing->control_flow_data),
event_request.x_begin = x;
event_request.x_end = x+width;
- g_critical("req : start : %u, %u", event_request.time_begin.tv_sec,
+ g_debug("req : start : %u, %u", event_request.time_begin.tv_sec,
event_request.time_begin.tv_nsec);
- g_critical("req : end : %u, %u", event_request.time_end.tv_sec,
+ g_debug("req : end : %u, %u", event_request.time_end.tv_sec,
event_request.time_end.tv_nsec);
LttvHooks *event = lttv_hooks_new();
// FIXME : would like to place the after_traceset hook after the traceset,
// but the traceset context state is not valid anymore.
lttv_traceset_context_add_hooks(tsc,
- // NULL, after_traceset, NULL, NULL, NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL,
- NULL, after_traceset, NULL, event, after_event);
+ NULL, after_traceset, NULL, NULL, NULL, NULL,
+ //NULL, NULL, NULL, NULL, NULL, NULL,
+ NULL, NULL, NULL, event, after_event);
lttv_process_traceset(tsc, end, G_MAXULONG);
//after_data_request((void*)&event_request,(void*)tsc);
lttv_traceset_context_remove_hooks(tsc,
- //NULL, after_traceset, NULL, NULL, NULL, NULL,
- NULL, NULL, NULL, NULL, NULL, NULL,
- NULL, after_traceset, NULL, event, after_event);
+ NULL, after_traceset, NULL, NULL, NULL, NULL,
+ // NULL, NULL, NULL, NULL, NULL, NULL,
+ NULL, NULL, NULL, event, after_event);
//Modified by xiangxiu: state update hooks are removed by the main window
//state_remove_event_hooks_api(control_flow_data->mw);
// widget->allocation.height + SAFETY,
// -1);
- g_critical("drawing configure event");
- g_critical("New draw size : %i by %i",widget->allocation.width, widget->allocation.height);
+ g_debug("drawing configure event");
+ g_debug("New draw size : %i by %i",widget->allocation.width, widget->allocation.height);
if (drawing->pixmap)
G_OBJECT(widget),
"control_flow_data");
- g_critical("drawing expose event");
+ g_debug("drawing expose event");
guint x=0;
LttTime* current_time =
Drawing_t *drawing = control_flow_data->drawing;
- g_critical("click");
+ g_debug("click");
if(event->button == 1)
{
LttTime time;
/* left mouse button click */
- g_critical("x click is : %f", event->x);
+ g_debug("x click is : %f", event->x);
convert_pixels_to_time(widget->allocation.width, (guint)event->x,
&control_flow_data->time_window.start_time,
set_current_time(control_flow_data->mw, &time);
}
+
+ set_focused_pane(control_flow_data->mw, gtk_widget_get_parent(control_flow_data->scrolled_window));
return FALSE;
}
LttTime window_middle =
ltt_time_add(half_width,
drawing->control_flow_data->time_window.start_time);
- g_critical("ruler expose event");
+ g_debug("ruler expose event");
gdk_draw_rectangle (drawing->ruler->window,
drawing->ruler->style->white_gc,
static gboolean
motion_notify_ruler(GtkWidget *widget, GdkEventMotion *event, gpointer user_data)
{
- //g_critical("motion");
+ //g_debug("motion");
//eventually follow mouse and show time here
}