From: compudj Date: Sun, 28 Sep 2003 01:22:08 +0000 (+0000) Subject: basic viewer showing X-Git-Tag: v0.12.20~3219 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=784177915a639df2d016b63ac6a9cce3101cc084;p=lttv.git basic viewer showing git-svn-id: http://ltt.polymtl.ca/svn@270 04897980-b3bd-0310-b5e0-8ef037075253 --- diff --git a/ltt/branches/poly/lttv/modules/guiControlFlow/CFV.c b/ltt/branches/poly/lttv/modules/guiControlFlow/CFV.c index 9cea4bc9..9a29ae1a 100644 --- a/ltt/branches/poly/lttv/modules/guiControlFlow/CFV.c +++ b/ltt/branches/poly/lttv/modules/guiControlFlow/CFV.c @@ -149,22 +149,28 @@ GuiControlFlow(void) } +/* Destroys widget also */ +void +GuiControlFlow_Destructor_Full(ControlFlowData *Control_Flow_Data) +{ + /* May already have been done by GTK window closing */ + if(GTK_IS_WIDGET(Control_Flow_Data->Scrolled_Window_VC)) + gtk_widget_destroy(Control_Flow_Data->Scrolled_Window_VC); + + GuiControlFlow_Destructor(Control_Flow_Data); +} + void GuiControlFlow_Destructor(ControlFlowData *Control_Flow_Data) { guint index; - /* May already been done by GTK window closing */ - if(GTK_IS_WIDGET(Control_Flow_Data->Scrolled_Window_VC)) - gtk_widget_destroy(Control_Flow_Data->Scrolled_Window_VC); - //ProcessList_destroy(Control_Flow_Data->Process_List); g_slist_remove(gControl_Flow_Data_List,Control_Flow_Data); + g_free(Control_Flow_Data); } -//FIXME : call hGuiEvents_Destructor for corresponding data upon widget destroy - GtkWidget *GuiControlFlow_get_Widget(ControlFlowData *Control_Flow_Data) { return Control_Flow_Data->Scrolled_Window_VC ; diff --git a/ltt/branches/poly/lttv/modules/guiControlFlow/CFV.h b/ltt/branches/poly/lttv/modules/guiControlFlow/CFV.h index 9088e6e1..1855fb27 100644 --- a/ltt/branches/poly/lttv/modules/guiControlFlow/CFV.h +++ b/ltt/branches/poly/lttv/modules/guiControlFlow/CFV.h @@ -8,6 +8,8 @@ typedef struct _ControlFlowData ControlFlowData; /* Control Flow Data constructor */ ControlFlowData *GuiControlFlow(void); void +GuiControlFlow_Destructor_Full(ControlFlowData *Control_Flow_Data); +void GuiControlFlow_Destructor(ControlFlowData *Control_Flow_Data); GtkWidget *GuiControlFlow_get_Widget(ControlFlowData *Control_Flow_Data); diff --git a/ltt/branches/poly/lttv/modules/guiControlFlow/module.c b/ltt/branches/poly/lttv/modules/guiControlFlow/module.c index 41b77a6d..5b73abae 100644 --- a/ltt/branches/poly/lttv/modules/guiControlFlow/module.c +++ b/ltt/branches/poly/lttv/modules/guiControlFlow/module.c @@ -68,7 +68,7 @@ G_MODULE_EXPORT void init(LttvModule *self, int argc, char *argv[]) { void destroy_walk(gpointer data, gpointer user_data) { - GuiControlFlow_Destructor((ControlFlowData*)data); + GuiControlFlow_Destructor_Full((ControlFlowData*)data); g_critical("Walk destroy GUI Control Flow Viewer"); }