1 /* This file is part of the Linux Trace Toolkit viewer
2 * Copyright (C) 2006 Mathieu Desnoyers
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License Version 2 as
6 * published by the Free Software Foundation;
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
13 * You should have received a copy of the GNU General Public License
14 * along with this program; if not, write to the Free Software
15 * Foundation, Inc., 59 Temple Place - Suite 330, Boston,
20 #include "lttv_plugin_evd.h"
21 #include <lttvwindow/lttvwindow.h>
32 static void evd_update_filter(LttvPlugin
*parent
, LttvFilter
*filter
)
34 LttvPluginEVD
*self
= LTTV_PLUGIN_EVD(parent
);
35 g_message("In EVD update filter.");
36 lttv_filter_destroy(self
->evd
->filter
);
37 self
->evd
->filter
= filter
;
38 evd_redraw_notify(self
->evd
, NULL
);
40 #endif //babel cleanup
43 lttv_plugin_evd_class_init (LttvPluginEVDClass
*klass
)
45 LttvPluginClass
*parent_klass
;
46 parent_klass
= &klass
->parent
;
48 parent_klass
->update_filter
= evd_update_filter
;
49 #endif //babel cleanup
50 g_type_class_add_private (klass
, sizeof (EventViewerData
));
55 lttv_plugin_evd_init (GTypeInstance
*instance
, gpointer g_class
)
57 LttvPluginEVD
*self
= LTTV_PLUGIN_EVD (instance
);
58 self
->evd
= G_TYPE_INSTANCE_GET_PRIVATE (self
,
59 LTTV_TYPE_PLUGIN_EVD
, EventViewerData
);
64 lttv_plugin_evd_get_type (void)
66 static GType type
= 0;
68 static const GTypeInfo info
= {
69 sizeof (LttvPluginEVDClass
),
71 NULL
, /* base_finalize */
72 (GClassInitFunc
) lttv_plugin_evd_class_init
, /* class_init */
73 NULL
, /* class_finalize */
74 NULL
, /* class_data */
75 sizeof (LttvPluginEVD
),
77 lttv_plugin_evd_init
/* instance_init */
79 type
= g_type_register_static (G_TYPE_OBJECT
,