diff options
author | etxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7> | 2011-08-20 09:55:32 +0000 |
---|---|---|
committer | etxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7> | 2011-08-20 09:55:32 +0000 |
commit | 572704db874535584c44fc43989ba225f990a718 (patch) | |
tree | cfe15bd831659ccd9570d2b4d088208e2172b5e2 /gtk/tap_param_dlg.c | |
parent | 6a8f2bda3bc3f827e4bff1a2700f26b6c92cdbcb (diff) |
Make register_dfilter_stat work for MAIN_MENU_USE_UIMANAGER
and add a bunch of menus.
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@38626 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'gtk/tap_param_dlg.c')
-rw-r--r-- | gtk/tap_param_dlg.c | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/gtk/tap_param_dlg.c b/gtk/tap_param_dlg.c index 68d5572468..e7d9d8fd5a 100644 --- a/gtk/tap_param_dlg.c +++ b/gtk/tap_param_dlg.c @@ -66,9 +66,10 @@ static tap_param_dlg_list_item *start_dlg_list=NULL; static tap_param_dlg_list_item *end_dlg_list=NULL; static tap_param_dlg_list_item *current_dlg = NULL; -static void -tap_param_dlg_cb(GtkWidget *w, gpointer data); - +#ifdef MAIN_MENU_USE_UIMANAGER +#else +static void tap_param_dlg_cb(GtkWidget *w, gpointer data); +#endif /* * Register a stat that has a parameter dialog. * We register it both as a command-line stat and a menu item stat. @@ -77,10 +78,12 @@ void register_dfilter_stat(tap_param_dlg *info, const char *name, register_stat_group_t group) { +#ifdef MAIN_MENU_USE_UIMANAGER + register_stat_cmd_arg(info->init_string, info->tap_init_cb, NULL); +#else char *full_name; register_stat_cmd_arg(info->init_string, info->tap_init_cb, NULL); - /* * This menu item will pop up a dialog box, so append "..." * to it. @@ -89,6 +92,7 @@ register_dfilter_stat(tap_param_dlg *info, const char *name, register_stat_menu_item(full_name, group, tap_param_dlg_cb, NULL, NULL, info); /* tap_menu_item_add() uses the name later on. Leave it allocated. */ +#endif } void tap_param_dlg_update (void) @@ -145,9 +149,13 @@ tap_param_dlg_start_button_clicked(GtkWidget *item _U_, gpointer dialog_data) g_string_free(params, TRUE); } - +#ifdef MAIN_MENU_USE_UIMANAGER +void +tap_param_dlg_cb(GtkAction *action _U_, gpointer data) +#else static void tap_param_dlg_cb(GtkWidget *w _U_, gpointer data) +#endif { const char *filter; char *title; |