X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;f=ltt%2Fbranches%2Fpoly%2Flttv%2Fmodules%2Fgui%2Fcontrolflow%2Feventhooks.c;h=65f47eec4a17c250afd1763f7d6a6cf784bc0a52;hb=7df20ca43b06343b299d2a79512a44441f148f1d;hp=97d09da548d7012638b96cd25fb6bc480f1c5ddc;hpb=0f090e217d9fe272c8114e229cd5824305c4b4fe;p=lttv.git diff --git a/ltt/branches/poly/lttv/modules/gui/controlflow/eventhooks.c b/ltt/branches/poly/lttv/modules/gui/controlflow/eventhooks.c index 97d09da5..65f47eec 100644 --- a/ltt/branches/poly/lttv/modules/gui/controlflow/eventhooks.c +++ b/ltt/branches/poly/lttv/modules/gui/controlflow/eventhooks.c @@ -79,6 +79,8 @@ #define MAX_PATH_LEN 256 +#define STATE_LINE_WIDTH 4 +#define COLLISION_POSITION(height) (((height - STATE_LINE_WIDTH)/2) -3) extern GSList *g_legend_list; @@ -120,6 +122,7 @@ static void request_background_data(ControlFlowData *control_flow_data) gint num_traces = lttv_traceset_number(tsc->ts); gint i; LttvTrace *trace; + LttvTraceState *tstate; LttvHooks *background_ready_hook = lttv_hooks_new(); @@ -129,8 +132,10 @@ static void request_background_data(ControlFlowData *control_flow_data) for(i=0;its, i); + tstate = LTTV_TRACE_STATE(tsc->traces[i]); - if(lttvwindowtraces_get_ready(g_quark_from_string("state"),trace)==FALSE) { + if(lttvwindowtraces_get_ready(g_quark_from_string("state"),trace)==FALSE + && !tstate->has_precomputed_states) { if(lttvwindowtraces_get_in_progress(g_quark_from_string("state"), trace) == FALSE) { @@ -157,7 +162,7 @@ static void request_background_data(ControlFlowData *control_flow_data) control_flow_data->background_info_waiting++; } } else { - /* Data ready. Be its nature, this viewer doesn't need to have + /* Data ready. By its nature, this viewer doesn't need to have * its data ready hook called there, because a background * request is always linked with a redraw. */ @@ -269,7 +274,7 @@ int event_selected_hook(void *hook_data, void *call_data) static inline PropertiesLine prepare_s_e_line(LttvProcessState *process) { PropertiesLine prop_line; - prop_line.line_width = 2; + prop_line.line_width = STATE_LINE_WIDTH; prop_line.style = GDK_LINE_SOLID; prop_line.y = MIDDLE; //GdkColormap *colormap = gdk_colormap_get_system(); @@ -451,7 +456,7 @@ int before_schedchange_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } } else { @@ -482,7 +487,7 @@ int before_schedchange_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } /* jump */ @@ -615,7 +620,7 @@ int before_schedchange_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } } else { @@ -647,7 +652,7 @@ int before_schedchange_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } /* jump */ @@ -978,7 +983,7 @@ int before_execmode_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } } else { @@ -1011,7 +1016,7 @@ int before_execmode_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } /* jump */ @@ -1173,7 +1178,7 @@ int before_process_exit_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } } else { @@ -1206,7 +1211,7 @@ int before_process_exit_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } /* jump */ @@ -1375,7 +1380,7 @@ int before_process_release_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } } else { @@ -1408,7 +1413,7 @@ int before_process_release_hook(void *hook_data, void *call_data) gdk_draw_point(hashed_process_data->pixmap, drawing->gc, x, - (hashed_process_data->height/2)-3); + COLLISION_POSITION(hashed_process_data->height)); hashed_process_data->x.middle_marked = TRUE; } /* jump */