aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt/proto_tree.h
AgeCommit message (Collapse)AuthorFilesLines
2016-04-02Qt: Remember selected item in packet treePeter Wu1-0/+3
Previously, changing a packet in the packet list would lose the currently selected field item in the packet tree. After this patch, this issue no longer occurs because the selected field is focussed again. The approach is to remember the header field ID on the path from a field to its root. Limitations of the current simple approach is that multiple fields/trees under a tree might result in the wrong selection. This is better than nothing though. This patch greatly helps analyzing a capture file which has the same format, except that I need to check a data source for decrypted data. Previously I would have to scroll down and select the field to see the data source which also made it impossible to quickly switch between packets and compare them. Change-Id: Ic113ca9245fd9faa10f91182794c50cfde8d10f4 Reviewed-on: https://code.wireshark.org/review/14697 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-03-11Qt: Defer proto tree column content resizing.Gerald Combs1-1/+7
Try to avoid the following call graph: ProtoTree::expandAll ... ProtoTree::expand ... QTreeView::resizeColumnToContents QTreeView::resizeColumnToContents calls sizeHintForColumn, which iterates over a number of items (default 1000). Calling it from ProtoTree::expand can lead to excessive wheel-spinning. Add a single-shot timer for resizeColumnToContents. This is similar to what QTreeView does internally when columns are resized. Bug: 12228 Change-Id: I7b50c1486b3a25817efae58efbb8c9e961dbdab0 Reviewed-on: https://code.wireshark.org/review/14411 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-02-23Qt: Select matching tree item and bytes in Find PacketStig Bjørlykke1-0/+1
Highlight the matching tree item and matching packet bytes when doing a Find Packet. Added cf->search_len to correctly highlight the matching bytes when doing a regex search. Bug: 12157 Change-Id: I84fbdb9b43be4355e24aff3cf5f8850f1119e2bf Reviewed-on: https://code.wireshark.org/review/14086 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2015-08-18Qt: Reload widgets using prefs when reloading Lua pluginsStig Bjørlykke1-0/+1
Widgets using prefs must be closed because the prefs may have been free'd when reloading Lua plugins. Change-Id: I4b79b7aff18d7923c77a9eb05acadc29b156edbf Reviewed-on: https://code.wireshark.org/review/10108 Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2015-07-30Add Colorize to the packet detail menu.Gerald Combs1-0/+2
Change-Id: Idaac0b52e6e4534f40e13839e6dbce2408ca6bfa Reviewed-on: https://code.wireshark.org/review/9831 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-07-30Packet list and detail context menu updates.Gerald Combs1-0/+1
Add some missing items to the packet list and detail "Copy" context menus. Don't nest the "Copy" items so deeply. Add YAML to the supported summary formats. Note that "Copy as Binary" copies to the clipboard as application/octet-stream, which is a) arguably correct, and b) not very useful. Fixes welcome. Enable and disable packet detail context menu items from a set of booleans similar to the packet list. Change-Id: Iaa931c766aa476c33f27de089e5c4dbaf9ce74d6 Ping-Bug: 9320 Bug: 10831 Reviewed-on: https://code.wireshark.org/review/9825 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-06-18Add a preferences editor frame.Gerald Combs1-0/+1
This replaces the single preference editor dialog in the GTK+ UI. Change-Id: I10e030981e9f7d1ec121811593586b65cf0797c5 Reviewed-on: https://code.wireshark.org/review/8966 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-06-17Qt: Add protocol preferences menus.Gerald Combs1-0/+4
Add protocol preferences in the packet list and packet detail context menus. Note that we need a PreferencesEditorFrame in the main window for editing numeric and string preferences. For now we just show the prefs dialog. Change-Id: Ice0cc8e9bc25963cc14aa47698f042f2a73088d8 Reviewed-on: https://code.wireshark.org/review/8957 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-05-29Qt: Add Conversation Filter sub menuAlexis La Goutte1-0/+1
Apply conversation filters using the new color_dissector_filters.[ch] from g1f03180. Change-Id: I2e535bb3d5b95fd26226422daf9f83c452a95e3c Reviewed-on: https://code.wireshark.org/review/3558 Petri-Dish: Gerald Combs <gerald@wireshark.org> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-05-08Expert Info dialog.Gerald Combs1-0/+1
Show all expert messages in a combined view. Group top-level items by a (severity, group, protocol) tuple. Let the user enable and disable messages via a check menu. Add ProtoTree::goToField and expert_info_t.hf_index. Use them to jump to what we hope is the afflicted item. Enable the context menu only if the user has selected a packet item. Add a free-form search field that matches expert summaries. This differs from the GTK+ version but hopefully provides a smoother workflow. Bug: 10931 Change-Id: Ia12cb7c27cdea1634fa2798fb7e4c1b23bd16ad2 Reviewed-on: https://code.wireshark.org/review/8294 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-03-05Qt: Constify a bunch of strings.Gerald Combs1-1/+1
Change-Id: I601e429408fc042fc5b18a4750d40e260da47f43 Reviewed-on: https://code.wireshark.org/review/7535 Petri-Dish: Gerald Combs <gerald@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-03-05Qt: Add extra related packet indicator types.Gerald Combs1-2/+2
Add the ability to set frame number types: none, request, or response. Use the types to draw different related packet indicators in the packet list. Track the conversation in PacketListRecord. Use it to draw dashed lines for unrelated frames. Set frame number types for DNS and ICMP. Instead of drawing a transparent QImage, alpha blend our foreground color and draw directly in our painter. Blend more toward the foreground color. Add FRAMENUM_TYPE to checkAPIs. Change-Id: I2495945bb436413e05d6ec697184a0b4fd5ad214 Reviewed-on: https://code.wireshark.org/review/7436 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-02-13Qt: Allow shift-double-clicking on a frame link.Gerald Combs1-1/+2
You can open a new packet window in the GTK+ UI by holding down the shift key and double-clicking on a frame link in the protocol tree. Add this behavior to the Qt UI. Document the different ways of opening a new packet window and update the image. Change-Id: I55caf6cc8089a6c305fafd47b4870e7c69dbfb10 Reviewed-on: https://code.wireshark.org/review/7101 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-01-04Fix out-of-tree build includes of config.hGraham Bloice1-1/+1
If a file in the same directory as config.h, e.g. wireshark-qt.cpp has a #include "config.h", or another header it includes also has a #include "config.h", then an out-of-tree build, e.g. CMake will pick up any in-tree config.h and odd things may happen. The correct form is #include <config.h> which will pick up the out-of-tree version. To find this, introduce a deliberate error and then make an out-of-tree build, noting where it fails and fix that file. If that file includes other files that still cause the build to fail, set the compiler to emit the pre-processed version so you can locate the include with the next errant "config.h". Repeat ad nauseum. Possibly all includes of "config.h" should be changed to <config.h> Revert "CMake: Clobber the top-level config.h before we build." This reverts commit 1f3849ce614aeae5fda742beffe5558e7c2a8b71. Ping-Bug: 10301 Change-Id: Ie567e7cc696fd48f3e730fc27032c5d2a7d8f341 Reviewed-on: https://code.wireshark.org/review/6285 Reviewed-by: Graham Bloice <graham.bloice@trihedral.com> Petri-Dish: Graham Bloice <graham.bloice@trihedral.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2014-11-04Qt: Dynamic languagesMichal Labedzki1-3/+3
- get language as soon as possible (before creating any Qt objects) to make all translations working - dynamic list of supported languages - runtime change of GUI language (no need to restart application) - add flags icons support - search for *.qm languages in buildin resources, then data dir called "languages" (main directory in sources or /usr/share/wireshark/languages), then user directory (UNIX: ~/.wireshark/languages); "languages" directory should contains files wireshark_xx.qm where xx is language code (en, en_GB, etc.), and optional xx.svg for flag icon - try to fix some untranslated manually-created UI items (need manual reset text of those components) Change-Id: I62ca8a8cddce47cec9dbcad6b0bd68b6cfd92229 Reviewed-on: https://code.wireshark.org/review/5041 Tested-by: Michal Labedzki <michal.labedzki@tieto.com> Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2014-09-23Qt: Add zoom and column resize actions.Gerald Combs1-0/+2
Plumb signals and slots for changing the text size in the main window. Remove the bold font code from WiresharkApplication. It was only used in ByteViewText. Adjust the icons a bit. Bug: When we change the font preferences the packet list stops drawing cached strings. I haven't been able to track down the cause. Change-Id: I609d740c9f26265628fa4b7de1b75b0e56651387 Reviewed-on: https://code.wireshark.org/review/4269 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2014-03-04Remove all $Id$ from top of fileAlexis La Goutte1-2/+0
(Using sed : sed -i '/^ \* \$Id\$/,+1 d') Fix manually some typo (in export_object_dicom.c and crc16-plain.c) Change-Id: I4c1ae68d1c4afeace8cb195b53c715cf9e1227a8 Reviewed-on: https://code.wireshark.org/review/497 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2013-12-10Add "Decode As" to the packet list and protocol tree context menus.Gerald Combs1-0/+1
Automatically add a new item if "Decode As" is triggered from the context menus. svn path=/trunk/; revision=53915
2013-07-08New Qt feature: Show related packet list items in the frame numberGerald Combs1-0/+2
column. Conversation spans (setup frame to last frame) are shown with a square bracket. Linked frames are shown with a circle. Use correct column justifications in Qt. Move common justification-related packet list code to ui/packet_list_utils.[ch]. Add a last_frame element to conversation_t. svn path=/trunk/; revision=50447
2012-12-07Implement the items under "Edit→Copy", "Analyze→Apply as Filter" andGerald Combs1-0/+5
"Analyze→Prepare a Filter". Add a context menu to the protocol tree and fill in the items we've implemented so far. Add an "applyAllPreferences" method and corresponding "preferencesUpdated" signal to wsApp. Use it to set the maximum display filter combo count. Move the packet filtering code from the display filter edit to the main window (which makes more sense and matches what we're doing in the GTK+ version and gets rid of more global cfile references). Try to center the display filter edit button images. Use a different "close" button in the main toolbar. It looks better but is still wrong (on OS X at least). svn path=/trunk/; revision=46434
2012-10-16Add "Export Packet Bytes".Gerald Combs1-1/+1
svn path=/trunk/; revision=45567
2012-09-04Add modelines for Qtshark fileAlexis La Goutte1-0/+13
svn path=/trunk/; revision=44766
2012-08-19Handle double-clicks in the tree.Gerald Combs1-0/+2
svn path=/trunk/; revision=44592
2012-08-19Add automatic tree expansion. Get rid of some unnecessary void * casts.Gerald Combs1-0/+5
Fix a couple of compilation warnings. svn path=/trunk/; revision=44587
2012-08-14Properly enable and disable "View/Expand Subtrees". Get ridGerald Combs1-1/+1
of ProtoTree::protoItemUnselected and use an empty string in protoItemSelected to indicate that nothing is selected. svn path=/trunk/; revision=44492
2012-08-14Add a "View" menu along with actions+slots for expanding and collapsingGerald Combs1-1/+1
packet details. Connect the "Go" menu actions directly to their corresponding packet list slots. svn path=/trunk/; revision=44483
2012-06-28Update Free Software Foundation address.Jakub Zawadzki1-1/+1
(COPYING will be updated in next commit) svn path=/trunk/; revision=43536
2012-01-14Initial status bar functionality. Promote the main window's status barGerald Combs1-1/+7
to a MainStatusBar. Add a "LabelStack" widget, which MainStatusBar uses to duplicate features in GtkStatusbar. Make the protocol tree a full-blown ProtoTree widget. Move main_cf_callback from main to WiresharkApplication. Duplicate a lot of the cf callbacks as signals and slots. Use Q_UNUSED in a few places. svn path=/trunk/; revision=40488
2012-01-04Add initial support for Qt along with a "ui" subdirectory.Gerald Combs1-0/+47
svn path=/trunk/; revision=40378