aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt/follow_stream_text.h
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2016-02-29 16:34:32 -0800
committerGerald Combs <gerald@wireshark.org>2016-04-06 23:37:34 +0000
commitf611edf4e6061003d4eca88443c54b68d500cecd (patch)
tree4652e6ef9f9bbc59bdb9a7cfba0dbb5d22d8c53b /ui/qt/follow_stream_text.h
parent2b2a9896811b237346b4f5c35e17a2dfd5f3ea97 (diff)
Qt: Follow stream performance improvements.
Make FollowStreamText a subclass of QPlainTextEdit instead of QTextEdit. For large amounts of text, the former should be less unbearably slow than the latter. Increase the maximum stream size to 500MB. This isn't perfect but it's much more usable than 2MB and much easier than the next step, which is to write our own text display widget. Process UI events while we fill in the stream data. This gives us behavior similar to the GTK+ UI and is similar to what we do in other dialogs. Switch from g_memdup+g_free to a QByteArray in the Qt UI and GByteArray in the GTK+ UI. Don't call readStream twice. Make sure we free all of our stream data in the Qt UI. This fixes a serious memory leak. Ping-Bug: 11777 Change-Id: Ibad9bde86692ae07a80660566d1e661ab8b64601 Reviewed-on: https://code.wireshark.org/review/14271 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/follow_stream_text.h')
-rw-r--r--ui/qt/follow_stream_text.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/ui/qt/follow_stream_text.h b/ui/qt/follow_stream_text.h
index b6f8a2a598..000ad16c82 100644
--- a/ui/qt/follow_stream_text.h
+++ b/ui/qt/follow_stream_text.h
@@ -22,9 +22,9 @@
#ifndef FOLLOW_STREAM_TEXT_H
#define FOLLOW_STREAM_TEXT_H
-#include <QTextEdit>
+#include <QPlainTextEdit>
-class FollowStreamText : public QTextEdit
+class FollowStreamText : public QPlainTextEdit
{
Q_OBJECT
public: