Commit Graph

193 Commits

Author SHA1 Message Date
Stig Bjørlykke d5ea403f8d Qt: Fix packet bytes hover rectangle position
For Qt 5.11 and newer use horizontalAdvance() instead of boundingRect().width()
to calculate the width of a QString to position the hover rectangle position,
and to select which byte(s) to highlight.

Closes #17033.

(cherry picked from commit cb3b469d7f)
2020-12-09 09:54:16 +00:00
Orgad Shaneh 29e59a0e20 Qt: fix Qt 5.15 deprecation warning
QFont::ForceIntegerMetrics is deprecated.
2020-11-30 14:51:45 +00:00
Gerald Combs 8b80b9111a Qt: Fix QCustomPlot deprecation warnings.
Fix Qt 5.15 deprecation warnings in QCustomPlot, similar to 76d92ba7e7.

Use default flags constructors instead of 0.

Use QWheelEvent::angleDelta() instead of QWheelEvent::angle().

Use QWheelEvent::position() instead of QWheelEvent::pos().

Use date::startOfDay() instead of QDateTime(date).

Use QMultiMap instead of QMap where needed.
2020-10-22 07:19:14 +00:00
Gerald Combs 4955219d1a Qt: Add a filter button menu indicator.
Fixes #16918.
2020-10-20 17:49:20 +00:00
Gerald Combs 5b8a54ab14 Qt: Add a dark mode warning background.
Add ColorUtils::warningBackground, which returns a theme-appropriate
background color for warnings. Use it where needed.
2020-10-16 23:12:17 +00:00
Roland Knall cfd9ffbb1b Qt: Show tooltips on submenu items
Tooltips should be shown on submenu entries

Closes !16912
2020-10-15 23:21:25 +00:00
Martin Kaiser 92e1b110f3 Qt: FieldFilterEdit: remove unused actions
The private members save_action_ and remove_action_ in class FieldFilterEdit
are not used. Remove them.

(It looks as if FieldFilterEdit was copied from DisplayFilterEdit, where
 those two actions are present and linked to slots...)
2020-10-14 03:53:45 +00:00
Gerald Combs 511fa081df Qt: Handle dark mode in syntax highlighting.
Add ColorUtils::contrastingTextColor, which chooses an appropriate text
color from the current application palette for a given background.

Use it in SyntaxLineEdit and FontColorPreferencesFrame for each state
background color.

Fixes #15840.
2020-10-06 19:24:59 +00:00
Gerald Combs d2da4c7afb Qt: Use … instead of UTF8_HORIZONTAL_ELLIPSIS in translated strings.
Run

$ gsed -i -e 's/\(tr *(.*".*\)" *UTF8_HORIZONTAL_ELLIPSIS/\1…"/' $( ag -l 'tr *\(.*" *UTF8_HORIZONTAL_ELLIPSIS' )
$ gsed -i -e 's/\(tr *( *\)UTF8_HORIZONTAL_ELLIPSIS *"/\1"…/' $( ag -l 'tr *\( *UTF8_HORIZONTAL_ELLIPSIS *"' )

in ui/qt. As discussed in #16812, the UTF8_ macros were required at one
time because we only allowed ASCII in our source code. However, that
requirement has since been relaxed and Qt's translation framework
doesn't handle concatenating strings and macros very well.
2020-10-01 06:40:14 +00:00
Stig Bjørlykke 9cd9f02b34 Qt: Fix filename used in header comment
Fix a cut'n'paste issue in the filename used in the header comment.
2020-08-24 08:27:22 +00:00
Stig Bjørlykke e189bd2996 Qt: Always pop empty filter syntax
When checking a filter the status message should always be pop'ed when
having an empty filter, regardless of having the clear button or not.

This will ensure the status message is removed when removing a display
filter using DisplayFilterEdit in other dialogs than Main.

Change-Id: I3c9a4933cd0c60ab624ea1939ffafecb58b3ffd5
Reviewed-on: https://code.wireshark.org/review/38052
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2020-08-06 05:27:27 +00:00
Stig Bjørlykke 4ac54e27b0 Qt: Fix status message issues in find packet search
Fix some status message and tooltip issues introduced when enabling
autocomplete on find packet search in g0162ba73.

1. Enable or disable completion only when search type is changed.
   This setting is used in checkDisplayFilter(), which used to be
   called *before* changing allowCompletion in updateWidgets(), and
   this was causing issues with wrong status messages.

2. Check filter (usually triggered by changes in the search line)
   or reset filter syntax (added by DisplayFilterEdit) when search
   type is changed. This will trigger an update of the status message
   and the tooltip.

3. Stop checking display filter if not doing completion (not display
   filter search). This will avoid setting a status message from a
   previous illegal display filter.

Ping-Bug: 16638
Change-Id: I1534d9494cc4d7b7a0583cb845c091ae709458ae
Reviewed-on: https://code.wireshark.org/review/38061
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-08-05 21:31:13 +00:00
Gerald Combs 898b00c9a1 Qt: Restore an attribution.
The ByteViewText widget has been refactored a few times. At one point it
was based on QHexView by Evan Teran, and had a comment saying so. A
later refactor removed the comment but didn't completely rewrite all of
the code. Put the comment back (and spell Evan's name correctly this
time around).

Change-Id: I2fe7779e1b6773a5e8b38d317ebfd26b07900272
Reviewed-on: https://code.wireshark.org/review/37989
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-07-30 05:31:06 +00:00
Stig Bjørlykke e1df757c46 Qt: Improve status bar messages
Use pushStatus() in C++ code, improve translation support and end
each message with a dot.

Change-Id: I3f673da4736c3fe49203048da282afa1abf92337
Reviewed-on: https://code.wireshark.org/review/37887
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-07-18 04:02:23 +00:00
Martin Mathieson 0162ba730a Enable display filter autocomplete on find packet search.
Bug: 16638
Change-Id: Ifd9c9e4392fdc3d32b2aa4466d5a7f2835893338
Reviewed-on: https://code.wireshark.org/review/37682
Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-07-05 07:46:41 +00:00
Stig Bjørlykke b8a330d2d5 Qt: Update ByteView recent settings on all tabs
The ByteView recent settings are common for all tabs. Ensure all
tabs are updated when display format or character encoding is changed.

This fixes an issue where the row_width is wrong and the menu action
checkmarks are out of sync after switching ByteView tab.

Change-Id: Ied25ac41467143f37327ccadcb821262eb86ef0a
Reviewed-on: https://code.wireshark.org/review/37655
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2020-07-03 06:11:56 +00:00
Roland Knall c0b7a1d6eb Qt: Fix separator for FilterExpressions
Change the separator from && to // due to popular support for
that separator instead.

Bug: 16498
Change-Id: I0ee934f3f8a7b9ff1c062b533046980e3feb3d99
Reviewed-on: https://code.wireshark.org/review/37465
Reviewed-by: Roland Knall <rknall@gmail.com>
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-06-15 05:03:35 +00:00
Gerald Combs 2ca5a14513 Qt: Fix some Qt 5.15 deprecation warnings.
Use Qt::ItemFlags() instead of 0.

Use QFileDialog::Options() instead of 0.

Use QComboBox::textActivated instead of QComboBox::activated.

Switch to just using Qt::WindowFlags() in GeometryStateDialog. This
*should* work for Qt 5.5 and earlier, but if it doesn't we can switch
back.

Change-Id: Iaf4e7efa1a11fc7f3325b449eef1be308cd21b45
Reviewed-on: https://code.wireshark.org/review/37349
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-06-01 08:20:01 +00:00
Gerald Combs 76d92ba7e7 Qt: Updates for 5.15.
Fix the following deprecation issues for Qt 5.15:

Use Qt::WindowFlags() instead of 0 in Qt >= 5.6.

Pass Qt::SkipEmptyParts instead of QString::SkipEmptyParts to QString::split() in Qt >= 5.15.

Use QMultiMap instead of QMap where we were using QMap::uniqeKeys().

Use QCP::Interactions() instead of 0.

Use '\n' instead of QTextStream::endl.

Use QWheelEvent::angleDelta() instead of QWheelEvent::angle().

Change-Id: Ie2d69d3a396c0821c2c34f506ddad6f8e22f7049
Reviewed-on: https://code.wireshark.org/review/37334
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-05-30 06:45:07 +00:00
Tomasz Moń 1d0b233f12 Qt: Stretch last packet list header section
Programatically show the master split widget before elements are added
to prevent pending resize events from resizing packet columns to insane
widths (in my case orders of magnitude higher than display resolution)

Such resize was occuring when loading capture file if configuration file
included hidden columns (e.g. 55 defined columns, 8 visible). The resize
was not directly visible to user. Resize event call chain included calls
to recent_set_column_width() that changed width stored in configuration.
Modified configuration column width value would become effective after
user added or removed columns.

Hide PacketList when freezing and show it when thawing. Do not call
setUpdatesEnabled(false) as it leads to widget/preferences columns
missynchronization.

Clear packet list before freeing frame data. This prevents accessing
freed memory in ProtoTree on file close if packet list was in focus and
the next widget to get focus is packet details.

Ping-Bug: 16063
Bug: 16491
Change-Id: I2c21d928348681af1793b3263815c81ee73d41b0
Reviewed-on: https://code.wireshark.org/review/37029
Petri-Dish: Tomasz Moń <desowin@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-05-06 03:50:18 +00:00
Pascal Quantin 50806f2f1b Qt: workaround a C4138 warning generated by MSVC2019
MSVC falsely reports a '*/' found outside of comment warning

Change-Id: I41366c9760f6b698a1c6a4309cdfa2f9828bb0c2
Reviewed-on: https://code.wireshark.org/review/36961
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
Petri-Dish: Martin Kaiser <wireshark@kaiser.cx>
Tested-by: Petri Dish Buildbot
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2020-04-28 16:06:31 +00:00
Martin Kaiser d8137cc1be ProfileTreeView: fix a memory leak
In the constructor, we allocate a delegate for the name column and assign
it by calling QAbstractItemView::setItemDelegateForColumn(). This does
not pass ownership of the delegate to QAbstractItemView, it's still
up to us to free the delegate.

ASAN warns about this

Indirect leak of 48 byte(s) in 1 object(s) allocated from:
...
    #1 ... in ProfileTreeView::ProfileTreeView(QWidget*) ui/qt/widgets/profile_tree_view.cpp:46:17
    #2 ... in Ui_ProfileDialog::setupUi(QDialog*) ui/qt/qtui_autogen/include/ui_profile_dialog.h:67:31
    #3 ... in ProfileDialog::ProfileDialog(QWidget*) ui/qt/profile_dialog.cpp:59:13
    #4 ... in MainWindow::on_actionEditConfigurationProfiles_triggered() ui/qt/main_window_slots.cpp:2239:36

Add a destructor for ProfileTreeView and free the delegate there.

Change-Id: I2a76abb7ec174c91ad15bfac91f2b47bea29f511
Reviewed-on: https://code.wireshark.org/review/36934
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
Petri-Dish: Martin Kaiser <wireshark@kaiser.cx>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-04-26 06:13:45 +00:00
Roland Knall e74ce4e1bc Qt: Fix compilation error
and also remove unnecessary method

Change-Id: If6dfc5ae2f5ddab97926beeaa611372cd487b98a
Reviewed-on: https://code.wireshark.org/review/36900
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2020-04-21 11:37:53 +00:00
Roland Knall 9c75c1dc18 Qt: Allow folders for filter buttons
Filter buttons can be sorted into folders, by separating
different depths by the parent separator "&&". Context
menu for filter buttons work also in submenus, and the
depth of submenus is only limited by the character limit
for the label

Bug: 16498
Change-Id: I9c784a36e8c46eede11f679a4c1ac830213de7ce
Reviewed-on: https://code.wireshark.org/review/36885
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2020-04-21 11:05:44 +00:00
Tomasz Moń 1d20a875e4 Qt: Fix bug causing hidden columns to be displayed
Set capture file for model and header before columnsChanged() is called
to prevent skipping model reset in PacketListModel::resetColumns() due
to cap_file_ being NULL.

Do not strech last section in packet list header. This prevents
QHeaderViewPrivate::resizeSections() from messing up the column sizes
via resize events. For some reason (unknown to me) underlying
QHeaderView implementation has different idea about the number of
visible columns than our code.

Ping-Bug: 16063
Change-Id: I482c1080adb418b7922ee99d357d4962dc086026
Reviewed-on: https://code.wireshark.org/review/36120
Petri-Dish: Tomasz Moń <desowin@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2020-03-15 12:07:06 +00:00
Jaap Keuter 40b8293d43 Qt: add new protocol name when reporting deprecation
When entering a deprecated protocol name in the filter a warning is
placed in the status bar to this effect. The new protocol name is
not reveiled though, leaving the user in doubt what to use.
This change adds the new protocol name to the text in the status bar.

Change-Id: Ib892f79893471065eca81c7cf17e165256fdc9a9
Reviewed-on: https://code.wireshark.org/review/36086
Petri-Dish: Jaap Keuter <jaap.keuter@xs4all.nl>
Tested-by: Petri Dish Buildbot
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2020-03-08 11:51:19 +00:00
Orgad Shaneh bc8140be0b Fix build and deprecation warnings with Qt 5.14
Change-Id: I1fa6b5d3105288d25717a9fe4ae93ad3f471aaca
Reviewed-on: https://code.wireshark.org/review/35727
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2020-01-10 08:42:21 +00:00
Roland Knall 936a844cc3 Qt: Fix PacketListHeader column
Due to changes in #35206, if you have a lot of columns the display
of all columns may be hindered depending on your screen resolution.

With this change, displaying the column information can be disabled
via a Preferences->Layout checkbox element. Additionaly, the column
information will always be displayed as a tooltip element

Bug: 16317
Change-Id: Ib8c0fc0a84deaca96631270b320f3a530ba87d89
Reviewed-on: https://code.wireshark.org/review/35706
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2020-01-09 12:32:34 +00:00
Orgad Shaneh 0442f7a2c3 UI: Fix compilation with Qt 5.14
Change-Id: I8adae4609ff2857cb12bc803839ebb2c6afbd264
Reviewed-on: https://code.wireshark.org/review/35517
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-12-21 20:25:51 +00:00
Gerald Combs c5093fb227 Qt: Remove a comment.
Remove a comment that's no longer relevant as of g14e4759b56.

Change-Id: I919631810c37e34ebc0cf5b78ab4dfbee5f5c687
Reviewed-on: https://code.wireshark.org/review/35390
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-12-10 16:37:44 +00:00
Gerald Combs 14e4759b56 Qt: Bump our minimum Qt version from 5.2. to 5.3.
Change-Id: Id6b39125a56b95b94d6a0bb6436bf7b2d131f924
Reviewed-on: https://code.wireshark.org/review/35385
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-12-10 08:48:57 +00:00
Dario Lombardo d884ff2cdc Qt: fix wrong checks.
If actions_ is NULL, it will be dereferenced in the next check.
Found by clang.

Change-Id: I11f1620fae0e330dbbb7e0cc57b398f473261899
Reviewed-on: https://code.wireshark.org/review/35373
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot
Reviewed-by: Michael Mann <mmann78@netscape.net>
2019-12-10 01:01:53 +00:00
Gerald Combs 7be2d964f0 Qt: We show preference panes using their module names.
PreferencesDialog::setPane takes a preference module name. Fix a
comparison in PrefModuleTreeView::setPane and update some variable names
in order to make things a bit more obvious.

Modernize some related code while we're here.

Bug: 16250
Change-Id: I8f4c7e5261a219e3f32e6e9a71574d81b1852219
Reviewed-on: https://code.wireshark.org/review/35304
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-12-04 20:31:59 +00:00
Gerald Combs f6953e378a Qt: Remove a couple of private variables.
ByteViewText and ProtoTree only use mono_font_ in setMonospaceFont, so
there's not much use in declaring it private in each case.

Change-Id: I3ad986052f6e013988ce851420f7f6e7b47b7ea8
Reviewed-on: https://code.wireshark.org/review/35255
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-11-28 22:54:46 +00:00
Gerald Combs f2dce23b40 Qt+macOS: Add /Volumes to the file dialog sidebar.
/Volumes is hidden on macOS, which means that it doesn't show up in Qt's
non-native file dialog. Add a constructor to WiresharkFileDialog that
adds /Volumes to the file dialog sidebar. Make CaptureFileDialog and
ExportDissectionDialog subclasses of WiresharkFileDialog.

Bug: 13840
Change-Id: I4d7da3948b203eb11fb64fa056eb42a448edf914
Reviewed-on: https://code.wireshark.org/review/35201
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-11-26 05:37:37 +00:00
Stig Bjørlykke 6433e12474 Qt: Show all column types in context menu
Show all column types in the column context menu to improve usability
even more when show/hide columns. This is a follow-up to the improvement
to show custom column field names.

Change-Id: I0838c7ae6eec59960a0a70b485c372855e242dc0
Reviewed-on: https://code.wireshark.org/review/35206
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-25 12:17:10 +00:00
Peter Wu 40897b0234 Qt: prevent inline completion from happening for filters
Commit v3.1.0rc0-1170-ga854811c4a replaced the deprecated
`setAutoCompletion(false)` call by `setCompleter(0)`. However, the
former has as side-effect that it prevents setLineEdit from creating a
custom completer. setCompleter on the other hand had no effect since
there was no existing completer.

To fix the issue, remove the completer after it is set by setLineEdit.
This has no effect on the completer from CaptureFilterEdit and
DisplayFilterEdit instances since they override the completer from
QLineEdit. To avoid any confusion, SyntaxLineEdit::setCompleter (and
completer) should probably be renamed, these are not used by QComboBox
since it is not marked as virtual method.

Bug: 16132
Change-Id: Iad619122eddb43eb4963347982bf65dacd29629b
Fixes: v3.1.0rc0-1170-ga854811c4a ("Qt: fix more more Qt 5.13 deprecation warnings")
Reviewed-on: https://code.wireshark.org/review/35198
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-25 12:16:34 +00:00
Peter Wu 27f9606932 Qt: fix display filter completion with few recent entries
If 1) the recent filters menu has less than 10 entries and 2) the cursor
position is not at the end of the filter, then completion would fail.
Additionally, pressing Enter on filters with syntax errors would also
end up being saved, unintentionally.

Fix these by disabling automatic addition of entries by Qt.

Change-Id: I612c6cb8f317beb5459919b5c65b837db6150d07
Reviewed-on: https://code.wireshark.org/review/35150
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-11-24 18:28:23 +00:00
Roland Knall 8f90446db5 Qt: Refactor ExportObjectsDialog
Add the following features:

- search now operates live (enter text changes the list live)
- filter by content-types
- Preview certain content types directly from the dialog

Change-Id: If47b64d475dd3e77485a28e8443a3e139e9bd1a4
Reviewed-on: https://code.wireshark.org/review/35182
Reviewed-by: Roland Knall <rknall@gmail.com>
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-11-22 05:10:16 +00:00
Roland Knall cfee0f8082 Qt: Remove frameSelect signal
As all frameSelect signals now transport a QList<int> of selected
frames, use this instead

Change-Id: I1888e45a4df997920aebde9706ca0ae803bdba03
Reviewed-on: https://code.wireshark.org/review/35176
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-21 10:59:05 +00:00
Roland Knall f211624fa6 Qt: Display selected rows in overlay bar
Indicate all selected rows in the overlay bar for the PacketList

Change-Id: Icddf8607b59bde12701a7e7983df6acbf26e0d23
Reviewed-on: https://code.wireshark.org/review/35161
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-20 16:22:02 +00:00
Roland Knall 8633ca6a88 Qt: Correct drag and drop with column header
Drag and Drop used the wrong filter name, fixing by using the correct one
and re-establish the feature

Change-Id: I7b3722c8087b4af7f2ea74f833ea130cbec0d19e
Reviewed-on: https://code.wireshark.org/review/35118
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-17 22:44:48 +00:00
Stig Bjørlykke a51c58fa1b Qt: Cleanup space inside parentheses
Remove randomly used space inside parentheses to make the coding
style uniform. Add space after if, for and while.

Change-Id: I519f5994b6f73d8a57a5004d51ca460276c618fe
Reviewed-on: https://code.wireshark.org/review/35112
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-17 20:43:10 +00:00
Stig Bjørlykke 9dbf684c71 Qt: Show custom column fields in context menu
Show the custom column field name in the column context menu to
improve usability when show/hide columns. The column title alone
may not be sufficient to separate different columns.

Change-Id: I52f249433b8090249af87725fa97eba302692918
Reviewed-on: https://code.wireshark.org/review/35088
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-14 09:53:25 +00:00
Stig Bjørlykke 7da6109f3b Qt: Fix column alignment check in context menu
Don't indicate "Align Left" when the column has default alignment,
because that may be wrong. Add back support for turning off custom
column alignment.

This is a regression from ge39f2bb5.

Change-Id: Ib9dc24067b02a44ffb2f3cd387f1c1c2a5c780ab
Reviewed-on: https://code.wireshark.org/review/35087
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-14 09:50:22 +00:00
Roland Knall c91bb19da2 Qt: Fix displayfilteredit pop
Fixing the status message disappearing from the status bar

Change-Id: I16925a5a8ad6ac929e1c4da8e36e3cf8fa29db84
Reviewed-on: https://code.wireshark.org/review/35084
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-13 15:38:09 +00:00
Roland Knall 3c8c392b9d Qt: Cleanup push/pop Infos
Currently push pop is propagated by a massive load of signals
which partly are also propagated through parent objects.

This moves the status handling to WiresharkApplication, also
pathlining future moves to move status to different classes or
use additional methods of status information

Change-Id: Ibcb2c98688f1adf40dce1483f336596ef992bb06
Reviewed-on: https://code.wireshark.org/review/35071
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-12 22:03:23 +00:00
Roland Knall 7a1a45c523 Qt: Signal empty display filter bar
If a display filter is applied, but the display filter bar
has been cleared by deleting the context (either by setting a
space or backspacing over the filter), it is not clearly indicated
that the filter is still being applied.

Bug: 12438
Change-Id: Ibd4c48b094467182ed51e9859e0d5fad770000c7
Reviewed-on: https://code.wireshark.org/review/35070
Petri-Dish: Roland Knall <rknall@gmail.com>
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-12 13:55:54 +00:00
Roland Knall c4e41e356a Qt: Make clearing display filter behave more logical
If the display filter is cleared, because it is emptied, the
new display filter ("") is not yet applied. This is not signaled
properly, as the user get's the expression, that no filter is applied,
although the old one still is. Visible is this by displaying
the placeholder text and removing the clear button

With this patch, in such a case, the placeholder text is empty
and the clear button still visible, until really an empty filter
is being applied.

Bug: 12438
Change-Id: I45128ebf2bc1854da5a4055d3980d913d0139a28
Reviewed-on: https://code.wireshark.org/review/35045
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-10 23:34:16 +00:00
Pascal Quantin 2d47c2060b CID: Fix 1455321 null-reference
Fix a null dereference in DisplayFilterEdit

Change-Id: I407e3d667ec8684312ba8fbcb0cc49130b9417df
Reviewed-on: https://code.wireshark.org/review/35025
Petri-Dish: Pascal Quantin <pascal@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Pascal Quantin <pascal@wireshark.org>
Reviewed-on: https://code.wireshark.org/review/35033
Petri-Dish: Roland Knall <rknall@gmail.com>
Reviewed-by: Roland Knall <rknall@gmail.com>
2019-11-09 14:17:08 +00:00