Commit Graph

406 Commits

Author SHA1 Message Date
Gerald Combs f5b7fcee5b Qt: SequenceDialog no longer emits goToPacket.
SequenceDialog no longer emits goToPacket as of g7fe45cc0ec. Don't try
to connect it in MainWindow.

Change-Id: I0f3e47a3cf7c1e29a64da7462c85179e29828c49
Reviewed-on: https://code.wireshark.org/review/23501
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2017-09-11 19:56:43 +00:00
Mikael Kanstrup 3b16cc8b21 iface_lists: Access ifaces member by reference
Change access of ifaces elements from by val to by reference.
With this change unnecessary copying of the whole struct is avoided
but even more important is that elements no longer have to be
removed and inserted whenever data is updated.

This change aims to make it more clear that ifaces elements shall
never directly be removed from the array. Instead use function
capture_opts_del_iface

NOTE: Code for GTK UI not updated

Ping-Bug: 13864
Change-Id: I04b65d5ee36526b30d959b8e5a2a48a3c7c4f15b
Reviewed-on: https://code.wireshark.org/review/23204
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-08-28 14:43:13 +00:00
Stig Bjørlykke 12c04e0529 Qt: Fix build without libpcap
Change-Id: I9b9b5de1beb23486ccc000feda54c2b20a33f4ad
Reviewed-on: https://code.wireshark.org/review/23251
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2017-08-28 06:37:09 +00:00
Håkon Øye Amundsen 018f6bff18 extcap: Interface Toolbar support on Windows
Add support for extcap control pipes on Windows.
Improved read loop in InterfaceToolbarReader.
Delay opening control pipes until extcap has opened the fifo pipe.
Make extcap_example.py work on Windows.

Bug: 13833
Change-Id: I4b47d25452637759b8a3be53be48eee5365bc0e4
Reviewed-on: https://code.wireshark.org/review/23211
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-08-28 05:48:01 +00:00
Roland Knall ddfc1d37cc Qt: Move utils to separate utils directory
Following the move for widgets directory, moving utils
to the utils directory. Guidelines for this directory are:

 - Generic use but not a widget
 - Utility functionality used by many classes
 
 Note: additionally all includes affected by this move have been changed
 to absolute path includes, instead of relative ones.

Change-Id: I019ae4b6e6f6d06a5745a63ed195edbd36fb936b
Reviewed-on: https://code.wireshark.org/review/22602
Petri-Dish: Roland Knall <rknall@gmail.com>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-07-26 10:11:55 +00:00
Roland Knall ee699eb720 Qt: Move all utility widgets to widgets subdirectory
Move all utility widgets to the widgets subdirectory and
add separate source_group for their files

Correct some alphabetization in ui/qt/CMakeLists.txt noticed
during compare.

Change-Id: I2d664edc2b32f126438fb673ea53a5ae94cd43d1
Reviewed-on: https://code.wireshark.org/review/22531
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Roland Knall <rknall@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-07-11 21:30:29 +00:00
Peter Wu bdd0965820 Qt: replace zoom buttons by wheel zoom in Wireless Timeline
There are already "zoom" buttons on the main toolbar, remove the
additional, confusing wireless timeline zoom buttons.

Implement zoom functionality by the mouse wheel instead and center at
the cursor position rather than the current packet. Properly bound the
maximum zoom level too to avoid incorrect calculations.

Change-Id: Icafe84b6985138b0223abb69c975dfc94df2817a
Ping-Bug: 13769
Reviewed-on: https://code.wireshark.org/review/22496
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-07-07 23:19:59 +00:00
Roland Knall a2fe8be603 Qt: Add convenience function and cleanup
Add a convenience function for the displayfilter combobox
and clean up some code. On Linux, the AltModifier does not work
as it is being used by xDMs to move the window around. Setting
it to Shift.

Change-Id: I1ee9638c1cf37f40dc21f19c4e0860adc4629d4e
Reviewed-on: https://code.wireshark.org/review/22529
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-07-06 13:21:10 +00:00
Roland Knall 8020be30fd Qt: Drag/Drop Filter buttons to order
Allow the ordering of the filter buttons via drag/drop in
the toolbar

Change-Id: Id8793d6514bae36066a7a23d6890985665e753bd
Reviewed-on: https://code.wireshark.org/review/22422
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-06-28 15:09:03 +00:00
Roland Knall 9731b50bc5 Qt: Change wording of filter button context menu
Change the wording to make it more like the other option
menus

Change-Id: I0d071aecd80131e5304737a1746f3a41f546c8e4
Reviewed-on: https://code.wireshark.org/review/22441
Petri-Dish: Roland Knall <rknall@gmail.com>
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-06-28 15:08:50 +00:00
Roland Knall 1426c44281 Qt: Context menu for toolbar filter buttons
Adds a context menu for the toolbar filter buttons, which allows for
opening the preference for the filter buttons, as well as direct edit,
removal and disable functionality

Change-Id: I5f2d132737c77804cf22834574dfe3c02f85fbdf
Reviewed-on: https://code.wireshark.org/review/22327
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-06-27 15:14:56 +00:00
Roland Knall 680d1df7a0 Fix Filter Tooltip button and frame
Make the frame into a two-row frame to better accomodate
the comments field, and reinstate the correct action for the
buttons

Change-Id: I171e4bc3c7f195b7179cd6b1c2ab4ab42ede9c04
Reviewed-on: https://code.wireshark.org/review/22405
Petri-Dish: Roland Knall <rknall@gmail.com>
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-06-26 14:33:37 +00:00
Michael Mann 7ecea31581 Change display filter button tooltip formatting.
Go from <expression>,<comment> to <comment>\n<expression>

Bug: 13814
Change-Id: I842e38798eba7ff87751733ce0b2befdc9c8c27f
Reviewed-on: https://code.wireshark.org/review/22395
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-06-26 06:27:24 +00:00
Michael Mann 5c60b517a7 Add support for comments for a display filter button
Add a field to the display filter button UAT to allow comments
to be displayed as part of the tooltip to the diplay filter
button

Bug: 13814
Change-Id: I74459e4102856258d31d6429e2fd924a9f798cd5
Reviewed-on: https://code.wireshark.org/review/22390
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-06-26 02:48:58 +00:00
Michael Mann 1b7f5d9f79 Convert filter expressions preference data to a UAT.
The filter expressions data was shoved into the preference file in a
very loose, non-arrayed form.  It's much easier to manage in code
(and for users in a separate file) as a UAT.

The GTK GUI was hacked to use the existing UAT dialog rather than
rewrite the pref_filter_expressions.c to support a UAT. Should
be okay since it's deprecated.

Change-Id: I688cebb4b7b6594878c1398365e79a205f1902d9
Ping-Bug: 13814
Reviewed-on: https://code.wireshark.org/review/22354
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-06-26 02:44:05 +00:00
Peter Wu 4deb97f31f Fix filter for "Next Packet in Conversation"
The "Previous/Next Packet in Conversation" actions accidentally
overwrites more specific filters (like TCP port matching) by less
specific ones (like IP addresses). This resulted in strange behavior
where packets from different TCP streams were selected.

Change-Id: Ifa93064e1db3777fa3c12e2220bbb0b36b9478fe
Reported-by: Christian Landström
Reviewed-on: https://code.wireshark.org/review/22274
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2017-06-20 20:34:23 +00:00
Peter Wu 4d90f2e092 Qt: make Wireless Timeline a separate item
Do not put the wireless timeline in the main view with splitters, it has
a fixed size anyway and is not taken into account for layout and size
calculations for the panes.

Bug: 13776
Change-Id: I71da962950c3f1b215908674f4852afa76744343
Reviewed-on: https://code.wireshark.org/review/22242
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Simon Barber <simon.barber@meraki.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-06-20 13:49:01 +00:00
Roland Knall d83176ed2e SearchBar - Focus on shortcut instead of closing
If the searchbar is already open focus on the bar and highlight
existing test, instead of closing an already open bar

Change-Id: I4f8ae2e903cb65c0ebca238f3bcc1c62b63b5c3b
Reviewed-on: https://code.wireshark.org/review/22223
Reviewed-by: Roland Knall <rknall@gmail.com>
Petri-Dish: Roland Knall <rknall@gmail.com>
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-06-19 15:23:15 +00:00
Simon Barber 21305e9835 Add a timeline view for packets, with the timing data used to generate the display
taken from the timing analysis done in the wlan_radio dissector. QT only.

The timeline background is light gray, white for packets displayed in the packetlist,
and blue for the currently selected packet. Packets are coloured according to the
colouring rules foreground colour. The timeline can be zoomed with controls on the
toolbar.

At higher zoom levels the duration (NAV) field is plotted as a horizontal line to the
right of a packet.

The height of a packet in the timeline is proportional to the RSSI.

The bottom half of the packet is only shown if it matches the display filter.

Todo:
Auto detect TSF timing reference point (start/end of packet)
Add a scrollbar
Add a ruler showing time
Improve handling of focus.
Do not display NAV for packets with bad FCS.
Show related packets graphically
Different Y axis modes
- bandwidth/channel use display
- different transmitters per line
- background color from coloring rules
Live capture support

Change-Id: Ic31fffb0d6854966361ade7abb5c0be50db9a247
Reviewed-on: https://code.wireshark.org/review/20043
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-06-05 11:25:51 +00:00
Stig Bjørlykke dc7b9cdb41 Qt: Disable -Wframe-larger-than= for ui_main_window.h
The generated Ui_MainWindow::setupUi() can grow larger than our configured
limit, so turn off -Wframe-larger-than= for ui_main_window.h.

Change-Id: I550ff30ebe566b711c63f7a9d0276e5b06244407
Reviewed-on: https://code.wireshark.org/review/21866
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2017-06-01 07:27:05 +00:00
Pau Espin 866178eb1f GTK+Qt: Show Osmux Packet Counter on Telephony menu
Change-Id: I565b0d2d43dd98781f77a302a20bd841e3e4650e
Reviewed-on: https://code.wireshark.org/review/21598
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2017-05-28 18:50:06 +00:00
Stig Bjørlykke 6bc71e4d0a Qt: Add check for packet bytes
Disable menu items handling packet bytes if not having any.

Bug: 13723
Change-Id: I9cdb1185910f865c61a8ee74e3cf3177159bf315
Reviewed-on: https://code.wireshark.org/review/21710
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>
2017-05-19 21:31:50 +00:00
Stig Bjørlykke 81bad32f2c Qt: Remove semicolon behind Q_UNUSED macro, part 2
Change-Id: Id27a93c9a76b554bb2e98199d08d3d9604550889
Reviewed-on: https://code.wireshark.org/review/21348
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2017-04-26 06:27:37 +00:00
Stig Bjørlykke 30d98d1ea9 Qt: Remove semicolon behind Q_UNUSED macro
Change-Id: I75ff975216da23447b94bc513671ac269c52b7dc
Reviewed-on: https://code.wireshark.org/review/21342
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>
2017-04-26 06:11:32 +00:00
Dario Lombardo 0557fe1446 Qt: fix compilation without pcap.
Change-Id: Ia0fe79157f21fd0b1c0e5195c902ae07c55ca253
Reviewed-on: https://code.wireshark.org/review/21343
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-25 23:14:00 +00:00
Stig Bjørlykke 77751c94f1 Qt: Add interface toolbar support
An extcap utility can provide configuration for controls to use in a
GUI interface toolbar.  This controls are bidirectional and can be
used to control the extcap utility while capturing.

This is useful in scenarios where configuration can be done based on
findings in the capture process, setting temporary values or give other
inputs without restarting current capture.

Todo:
- Add support for Windows

Change-Id: Ie15fa67f92eb27d8b73df6bb36f66b9a7d81932d
Reviewed-on: https://code.wireshark.org/review/19982
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>
2017-04-25 06:19:39 +00:00
Stig Bjørlykke 951cf710e8 Qt: AdditionalToolbars is a menu
Rename actionViewAdditionalToolbars to menuAdditionalToolbars
because this is a menu, not an action.

Change-Id: I85e45c065f415ffa008792f04127d81283e54b7e
Reviewed-on: https://code.wireshark.org/review/21181
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>
2017-04-18 09:21:30 +00:00
Guy Harris 2c44a7f930 Clean up handling of enabled/disabled protocols/heuristic dissectors.
Add a "report a warning message" routine to the "report_err" code in
libwsutil, and rename files and routines appropriately, as they don't
only handle errors any more.

Have a routine read_enabled_and_disabled_protos() that reads all the
files that enable or disable protocols or heuristic dissectors, enables
and disables them based on the contents of those files, and reports
errors itself (as warnings) using the new "report a warning message"
routine.  Fix that error reporting to report separately on the disabled
protocols, enabled protocols, and heuristic dissectors files.

Have a routine to set up the enabled and disabled protocols and
heuristic dissectors from the command-line arguments, so it's done the
same way in all programs.

If we try to enable or disable an unknown heuristic dissector via a
command-line argument, report an error.

Update a bunch of comments.

Update the name of disabled_protos_cleanup(), as it cleans up
information for disabled *and* enabled protocols and for heuristic
dissectors.

Support the command-line flags to enable and disable protocols and
heuristic dissectors in tfshark.

Change-Id: I9b8bd29947cccdf6dc34a0540b5509ef941391df
Reviewed-on: https://code.wireshark.org/review/20966
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-08 20:40:08 +00:00
Guy Harris 357cfd3b03 A bunch of "{Mac} OS X" -> "macOS" changes.
Avoid anachronisms, however; there was no "macOS 10.0" or even "OS X
10.0", for example.  It was "Mac OS X" until 10.8 (although 10.7 was
sometimes called "OS X" and sometimes called "Mac OS X"), and it was "OS
X" from 10.8 to 10.11.

Change-Id: Ie4a848997dcc6c45c2245c1fb84ec526032375c3
Reviewed-on: https://code.wireshark.org/review/20933
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-05 19:16:22 +00:00
Peter Wu 601fe5e351 Qt: propagate selection from main screen to dialog
Ensure that the selection in main screen is updated on refreshing
interfaces (InterfaceFrame::interfaceListChanged). Add additional
patches to ensure that selection changes from the main screen propagate
to the dialog and be careful to avoid infinite recursions.

Life of a signal for InterfaceFrame:

    ui->interfaceTree->selectionModel emits selectionChanged
    -> slot InterfaceFrame::interfaceTreeSelectionChanged
      -> emits InterfaceFrame::itemSelectionChanged
        -> slot MainWelcome::interfaceSelected
           -> emits MainWelcome::interfacesChanged
              -> slot CaptureInterfacesDialog::interfaceSelected
                 (updats dialog selection)

Life of a signal for CaptureInterfacesDialog:

    ui->interfaceTree emits itemSelectionChanged
    -> slot CaptureInterfacesDialog::interfaceSelected
       (emission of next signal because sender is ui->interfaceTree)
       -> emits CaptureInterfacesDialog::interfacesChanged
          -> slot InterfaceFrame::updateSelectedInterfaces
             (updates main screen selection)

This should probably be updated to model/view with shared selection
model in the future.

Change-Id: Ibb32c201a92bd2f1310523b3e6e63b03209c9ce4
Reviewed-on: https://code.wireshark.org/review/20487
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2017-03-29 15:16:56 +00:00
Stig Bjørlykke cf1d07c8e3 Qt: Apply selected bookmark display filter
When selecting a display filter from the bookmark list this filter
should be applied, because that's the most common action for a user.

Holding down the the Alt key will only prepare the filter.

Change-Id: I567ee8a2a70a3de07fea33fa5763d9efba591de3
Reviewed-on: https://code.wireshark.org/review/20317
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-03-04 00:57:09 +00:00
Gerald Combs 8e76cfbf54 Qt: Add selection history navigation.
Add the ability to move back and forth in the packet selection history
similar to GTK+. Update the documentation accordingly.

Change-Id: If1fdc1e59b240c0588c292dc0f7f0a5f083c30e1
Reviewed-on: https://code.wireshark.org/review/20320
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-03-03 05:02:14 +00:00
Stig Bjørlykke beea6736ab Qt: Code cleanup
Remove whitespace to match coding style used in file.

Change-Id: I4c1649aa02087cd39b2f516db6e40749899c5125
Reviewed-on: https://code.wireshark.org/review/20260
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2017-02-24 09:11:47 +00:00
Roland Knall 321386e9f4 PluginIF: AdditionalToolbar
Creates an interface for plugins and other parts of the code, to
add a new toolbar to the system and have various widget types interact
with this toolbar.

All toolbars added via this interface, will be added to an additional
submenu called "Additional Toolbars" within Wireshark.

Also a demo plugin is being provided, demonstrating various features
of the toolbar, including updating the gui elements. It also demonstrates
how to update toolbar items.

Change-Id: I8d0351224b3d7f4b90220d58970b51695551d7e3
Reviewed-on: https://code.wireshark.org/review/19803
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-02-24 08:12:46 +00:00
Stig Bjørlykke a4d7793b4c Qt: Avoid flicker in filter expressions toolbar
Calling adjustSize() on the display filter toolbar causes flicker
in the filter expression toolbar when switching between profiles
without buttons and in some cases changing to a profile without buttons.

Only calling adjustSize() if adding buttons should be fine to avoid
this issues, even if they may be caused by something else.

Change-Id: I8cca84a51dbbc8244dc4342ac0466e35884c294d
Reviewed-on: https://code.wireshark.org/review/20222
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jaap Keuter <jaap.keuter@xs4all.nl>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-02-22 05:37:49 +00:00
Stig Bjørlykke 6c654861d9 Qt: Mystery pixel issue is solved
The mystery pixel issue has probably been mysteriously solved earlier
because the adjustments does not work as expected now.

This fixes an issue where one of the panes increases with 1 pixel at
startup and when changing profile using layout type 3, 4, 5 and 6
(selection number 1, 4, 5 and 6 in “Preferences -> Appearance -> Layout”).

Change-Id: Iab36fa5303dc8628b21e5cf920e7c70a7167d76e
Reviewed-on: https://code.wireshark.org/review/20188
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-02-20 05:54:19 +00:00
Stig Bjørlykke b3f435ef54 Qt: Add "Reset Layout"
Add menu item "Reset Layout" to manually reset panes to equal sizes.

Change-Id: I1efbf655462e25053062e03f8038dc20f9f555c0
Reviewed-on: https://code.wireshark.org/review/20173
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-02-20 05:53:44 +00:00
Stig Bjørlykke 14e19128dc Qt: Disable pane menu items if not used in layout
If a pane is not used in the layout it should not be possible to show
and hide this from the menu, as this may give unexpected results.

Change-Id: I335168e66e1dffc89992cad480dd7daaea7e9d59
Reviewed-on: https://code.wireshark.org/review/20140
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>
2017-02-16 20:53:22 +00:00
Stig Bjørlykke 384c26622b Qt: Preserve pane sizes when layout content changed
Preserve pane sizes when rearranging layout content in the
preferences dialog.

Change-Id: I2af2a60424a7bf94f1f92e7c63e6a1823985b60d
Reviewed-on: https://code.wireshark.org/review/20145
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2017-02-16 20:53:00 +00:00
Stig Bjørlykke e2cef4cbbd Qt: Improved pane size auto detect
Split panes in exactly equal sizes.

Change-Id: I4b984931e860160791497a299011489aa26ad4ef
Reviewed-on: https://code.wireshark.org/review/20139
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>
2017-02-16 12:57:55 +00:00
Stig Bjørlykke a98eb3c312 Qt: Auto detect pane size when configured zero
The recent file configuration for pane sizes states that
“pane size of zero will auto detect”, so ensure we do this in
all cases where the settings may be zero.

This affects initial startup, Default profile reset and new profiles.

Change-Id: I1430ec1a83b7fb294b92837476f2bf9472384e45
Reviewed-on: https://code.wireshark.org/review/20121
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-02-16 05:13:50 +00:00
Stig Bjørlykke d718b1d7e1 Qt: Preserve pane sizes when changing profile
When changing between profiles having certain different layout types
the size of the last pane was calculated wrong.

This involves switching between this layout types:

   2 -> 3   2 -> 5   3 -> 1   3 -> 2   3 -> 4   3 -> 5
   4 -> 3   4 -> 5   5 -> 2   5 -> 3   5 -> 4   5 -> 6

Change-Id: I6ee3ed92c4c639b720587c0771be0a242e5a8793
Reviewed-on: https://code.wireshark.org/review/20116
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-02-16 05:08:45 +00:00
Stig Bjørlykke 6313e96e27 Qt: Hide "Go to Packet" frame when closing capture file.
The "Go to Packet" frame cannot be used without a capture file so
ensure we hide this when closing a capture file.

Change-Id: I339bc90b87181a8361e9f0bf27dfdf26d2f05333
Reviewed-on: https://code.wireshark.org/review/19783
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-01-27 05:07:14 +00:00
Gerald Combs a5fe96e50a Qt: Fixup drag and drop merging.
Make the behavior of MainWindow::dropEvent match the documentation and
dnd_open_file_cmd. If we've been passed a single file, open it. If we've
been passed multiple files, merge them first. Add an is_tempfile
parameter to openCaptureFile.

Add a note about setting the drop description on Windows.

Bug: 12129
Change-Id: I325a4da5a29e940b4efa7654627d8bcafba15b57
Reviewed-on: https://code.wireshark.org/review/19717
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-01-21 06:50:56 +00:00
Gerald Combs 05fbb4826b Qt: Show merge progress.
Add "file merge" callback plumbing. Use it to display "Merging files" in
the main statusbar.

Make sure we have a usable window pointer when we merge files.

Change-Id: I236b6edb30685f0b06703ab8304bc88ae592f83c
Reviewed-on: https://code.wireshark.org/review/19716
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>
2017-01-21 06:50:30 +00:00
Roland Knall 3df81a0550 Qt: Remove unneccessary Q_DECLARE_METATYPE
Remove unnecessary Q_DECLARE_METATYPE macros and replace calls
to QVariant conversions with VariantPointer where necessary

Change-Id: Ia4690590095f930bf94644197de7fa30b00ee7ec
Reviewed-on: https://code.wireshark.org/review/19611
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-01-12 16:04:00 +00:00
Gerald Combs 795f4eb106 Qt+Win32: Make software updates more friendly.
Add WinSparkle can_shutdown and shutdown_request callbacks which are
called prior to running the installer. Reject updates when we have
unsaved information. Add notes about possible improvements.

Ping-Bug: 9687
Ping-Bug: 12989
Change-Id: Ia126244b311417aa3105ea8136f186adc2745445
Reviewed-on: https://code.wireshark.org/review/19244
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>
2016-12-20 14:18:14 +00:00
Gerald Combs e150235ef1 Qt: Optionally restore our selected packet when thawing.
Stash the current row when we freeze the packet list. Make it possible
to restore it when thawing. Do so when the layout changes and when we
move a column.

Change-Id: I44cfb8bafcd4d49a46e1c89bf47aecf5ac139773
Reviewed-on: https://code.wireshark.org/review/19222
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-12-13 22:01:59 +00:00
Moshe Kaplan 20c57cb298 Enable exporting objects with tshark
A new "--export-object <protocol>,<destdir>" option is added to tshark.

This required refactoring Export Object behavior in all GUIs to give the
export object handling to the dissector, rather than the ui layer.
Included in the refactoring was fixing some serious memory leaks in Qt
Export Object dialog, crash due to memory scope issues in GTK Export
Object dialog, and addition sorting column feature in Qt dialog (set
up by creating a widget to manage the items that were previously
leaking memory)

Bug: 9319
Ping-Bug: 13174
Change-Id: I515d7662fa1f150f672b1476716f347ec27deb9b
Reviewed-on: https://code.wireshark.org/review/18927
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-12-02 16:07:35 +00:00
Gerald Combs 94344cd491 Qt: Fix a "No such slot" warning.
Make sure on_actionCaptureOptions_triggered always exists so that we
don't get a "No such slot" warning when building without libpcap.

Change-Id: Ib7c82df6c72bf080ff080e0a650216b345a97e9c
Reviewed-on: https://code.wireshark.org/review/18747
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-11-11 17:36:52 +00:00