diff options
author | Guy Harris <guy@alum.mit.edu> | 2015-04-05 16:42:35 -0700 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2015-04-05 23:43:01 +0000 |
commit | d4bfa9c43b05ccbdef212f55fb56b73a5033e5f6 (patch) | |
tree | 50d7e2029b9a8f002cd2e808bdf695a76a1173db /ui/capture_ui_utils.h | |
parent | 24af6eeeea3828bbf4e41ad70377aabc3f26252e (diff) |
Have a common routine for constructing strings listing interfaces.
We have a bunch of duplicated code to make those lists; make a common
routine for that. (dumpcap currently doesn't use it, as the routine in
question uses a routine in libui, which dumpcap doesn't use. We should
probably fix that.)
Change-Id: I9058bf3320d420b8713e90743618972da1d1c6ed
Reviewed-on: https://code.wireshark.org/review/7934
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'ui/capture_ui_utils.h')
-rw-r--r-- | ui/capture_ui_utils.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/ui/capture_ui_utils.h b/ui/capture_ui_utils.h index 50fb13073a..eb4cdf9db5 100644 --- a/ui/capture_ui_utils.h +++ b/ui/capture_ui_utils.h @@ -158,6 +158,23 @@ const char *get_iface_description_for_interface(capture_options *capture_opts, g */ extern void set_active_dlt(interface_t *device, int global_default_dlt); +/** Get a descriptive string for a list of interfaces. + * + * @param capture_opts The capture_options structure that contains the interfaces + * @param style flags to indicate the style of string to use: + * + * IFLIST_QUOTE_IF_DESCRIPTION: put the interface descriptive string in + * single quotes + * + * IFLIST_SHOW_FILTER: include the capture filters in the string + * + * @return A GString set to the descriptive string + */ +#define IFLIST_QUOTE_IF_DESCRIPTION 0x00000001 +#define IFLIST_SHOW_FILTER 0x00000002 + +extern GString *get_iface_list_string(capture_options *capture_opts, guint32 style); + #ifdef __cplusplus } #endif /* __cplusplus */ |