diff options
author | Guy Harris <guy@alum.mit.edu> | 2012-06-03 22:03:05 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2012-06-03 22:03:05 +0000 |
commit | dbfb305368f0178348fd613665a5f5bf05f62d8a (patch) | |
tree | b9609c547a4181a21a0de0b99e1e22a577782b69 /ui/gtk/gui_utils.h | |
parent | d1c1455882aa50f5ffdb5ba5dfdd6c4a4a45f649 (diff) | |
download | wireshark-dbfb305368f0178348fd613665a5f5bf05f62d8a.tar.gz |
g_filename_display_basename() returns a g_mallocated string, so its
callers either need to free it or their callers need to free it or....
This means that cf_get_display_name() must always return a g_mallocated
string and its callers or... must free it.
For some of those callers, create a new set_window_title() routine to do
the work - they're all using the same pattern.
svn path=/trunk/; revision=43047
Diffstat (limited to 'ui/gtk/gui_utils.h')
-rw-r--r-- | ui/gtk/gui_utils.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/ui/gtk/gui_utils.h b/ui/gtk/gui_utils.h index c941f3b7f5..79fa7b6ce4 100644 --- a/ui/gtk/gui_utils.h +++ b/ui/gtk/gui_utils.h @@ -297,6 +297,14 @@ extern void copy_binary_to_clipboard(const guint8* data_p, int len); */ extern gchar *create_user_window_title(const gchar *caption); +/** Set the title of a window based on a supplied caption and the + * display name for the capture file. + * + * @param win the window whose title is to be set + * @param caption caption string for the window + */ +extern void set_window_title(GtkWidget *win, const gchar *caption); + /** Renders a float with two decimals precission, called from gtk_tree_view_column_set_cell_data_func(). * the user data must be the colum number. * Present floats with two decimals |