diff options
author | Gerald Combs <gerald@wireshark.org> | 2016-03-18 10:34:41 -0700 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2016-03-28 16:27:41 +0000 |
commit | 6931f581f90d272474b47d4a4606bb93183f449a (patch) | |
tree | 08ff02c43d1896ea1d5e14bf28cd9288156e91c8 /ui/qt/qt_ui_utils.h | |
parent | 7e5dae90d65ed062f2d01c63174cc1c94850a19a (diff) | |
download | wireshark-6931f581f90d272474b47d4a4606bb93183f449a.tar.gz |
Qt: Make conversation menu items static.
Add a ConversationAction and ColorizeAction classes which respectively
handle conversation filtering and colorization.
Move conversation menu initialization to initConversationMenus and call
it once at startup. This keeps us from leaking quite a bit of memory
each time we select a packet or proto tree item.
Bug: 12044
Change-Id: I32e8cedaba08a419d5da6a7a9db31c910909f450
Reviewed-on: https://code.wireshark.org/review/14516
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Diffstat (limited to 'ui/qt/qt_ui_utils.h')
-rw-r--r-- | ui/qt/qt_ui_utils.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/ui/qt/qt_ui_utils.h b/ui/qt/qt_ui_utils.h index 4ca715e67d..3509b33130 100644 --- a/ui/qt/qt_ui_utils.h +++ b/ui/qt/qt_ui_utils.h @@ -71,6 +71,15 @@ gchar *qstring_strdup(QString q_string); */ QString gchar_free_to_qstring(gchar *glib_string); +/** Transfer ownership of a GLib character string to a newly constructed QString + * + * @param glib_string A string allocated with g_malloc() or NULL. Will be + * freed. + * + * @return A QByteArray instance created from the input string. + */ +QByteArray gchar_free_to_qbytearray(gchar *glib_string); + /** Transfer ownership of a GLib character string to a newly constructed QByteArray * * @param glib_gstring A string allocated with g_malloc() or NULL. Will be |