Commit Graph

1144 Commits

Author SHA1 Message Date
Srivats P
564687ffe3
Merge pull request #348 from Benni0109/master
Update portstatswindow.ui
2022-04-22 21:05:38 +05:30
Benjamin
9d4aaa4f7b
Update portstatswindow.ui 2022-04-16 19:14:44 +02:00
Srivats P
329469dd6e Calculate port tx duration and send to controller
This commit only includes server side changes plus the .proto changes.

Client side UI changes are still pending.
2022-02-21 22:20:59 +05:30
Srivats P
7374c74b95 Increase default width of port list pane
The list and detail panes were currently set to 1:2, so that the list
pane is 1/3rd the width. But for some reason it is not working like I
expect it to work. Setting it 1:1 looks better.
2022-02-12 19:26:18 +05:30
Srivats P
6f433bb7a1 Move View menu immediately after Edit menu
This seems to be the convention and also recommended by MacOS HIG
2022-02-11 18:34:06 +05:30
Srivats P
2ee19da15c Add Stream and Device menus to main window menu bar
Stream and Device related actions from the File menu has been moved
under these new menus
2022-02-11 18:09:30 +05:30
Srivats P
22b8c405f7 Use palette colors for stream stats
Using harcoded colors leads to unexpected results in dark mode.
2022-02-11 11:37:03 +05:30
Srivats P
2ce7f0c7a0 Disconnect portgroup before removing from list
Disconnecting _during_ remove sometimes causes crash because disconnect
triggers the logs window alert which **can** lead to repainting of
other windows which access port groups which have not been synced after
the removal of one or more portgroups.

Also emit endRemoveRows after each portgroup so that begin/end signals
match.
2022-02-10 20:34:10 +05:30
Srivats P
041f500e65 Avoid crash at GUI start up
The crash can happen before mainWindow is allocated. Don't remember how
that happens, but I have seen it happen!
2022-02-09 21:30:51 +05:30
Srivats P
7dd070fd98 Fix packet dump view bg color when using dark theme
Qt already paints the background before calling the paint event, so we
don't need to repaint it.
2022-02-07 21:44:40 +05:30
Srivats P
ac52844b3f Don't stretch stream config simple protocols widget
Only avoid the vertical stretch by adding a spacer, let horizontal still
stretch
2022-02-05 21:22:32 +05:30
Srivats P
2bf2973a23
Merge pull request #347 from pstavirs/themes
Add Ostinato Themes
2022-02-05 20:51:32 +05:30
Srivats P
341d0c3be8 Install themes as part of 'make install'
Tested only on Windows; pending on MacOS/Linux
2022-01-30 13:13:20 +05:30
Srivats P
6534312968 Look for themes in different locations on Mac/Unix
Not tested yet - since I'm coding this currently on Windows
2022-01-30 12:15:17 +05:30
Srivats P
a089cc1751 Update material themes and add qds themes 2022-01-29 12:24:08 +05:30
Srivats P
b0a81fb231 Change recalc cksum defaults implementation
These are the existing and desired defaults -
 * GUI: recalcCksum = true
 * PCAP import test: recalcCksum = false

With the existing implementation, doing PCAP import in 'raw' mode twice
would lead to recalcCksum being checked in the dialog the second time.
This was because we were always forcing it to be true for the GUI case
without checking for anything.
2022-01-23 21:46:42 +05:30
Srivats P
735e960dcb Use nsec pcap as intermediate when opening non-pcap
When opening a non-PCAP file, we convert it to intermediate PCAP format.
Use nanosecond pcap format instead of standard microsec pcap format for
higher timestamp resolution.

Updates #238
2022-01-19 18:54:46 +05:30
Srivats P
226705f015 Use integer storage and arithmetic for nanosec pcap
quint64 has larger range than double so has better accuracy. However,
for calculating packet rate, use floating-point arithmetic since the
packet rate is a double

Updates #238
2022-01-19 18:46:09 +05:30
Srivats P
45d5e15f23 Save PCAP always in nanosecond PCAP format
Updates #238
2022-01-17 18:49:24 +05:30
Srivats P
d09d83000e Add comment specifying PDML reader needs PCAP file
Updates #238
2022-01-15 18:36:15 +05:30
Srivats P
0f322fb2d8 Read nanosec PCAP files natively in non-pdml mode
In PDML mode, nanosecond support is already present - in fact, only
nanosecond is supported not microseconds.

Updates #238
2022-01-15 16:22:28 +05:30
Srivats P
0587e22de9 Add theme-manager and qt-material themes 2021-12-24 21:36:14 +05:30
Srivats P
5045b7f273 Update preferences.ui as per recent QtDesigner
No changes to the form - .ui file changes only because QtDesigner
generates the .ui file differently
2021-12-19 14:16:23 +05:30
Srivats P
a89400a4e5
Merge pull request #346 from pstavirs/find-replace
Find replace
2021-12-18 12:03:02 +05:30
Srivats P
db226d7069 Fix build break due to typo in #include files 2021-12-16 17:49:01 +05:30
Srivats P
f28e236276 Ensure mandatory fields to enable find-replace OK button 2021-12-15 21:28:52 +05:30
Srivats P
4bfd546f21 Change pcap import recalcCksum default to false
This was changed so that pcap import test produces minimal diffs like
earlier. However, for user, the import options dialog overrules this
default, so that user default remains recalcCksum as true
2021-12-12 11:06:36 +05:30
Srivats P
9208423372 Tweak find-replace UI
* matchAny op correctly hides findValue/findMask widgets
 * reorder widgets in the .ui file as per their actual appearance
 * remove tab order since the above reorder also fixes tab order
 * fix stretch factors so that UI redering doesn't change too much when
 things are checked/unchecked
2021-12-12 10:52:43 +05:30
Srivats P
16b353ae30 Alloc/free Pcap import options dialog every time
The earlier code was trying to reuse the dialog but this was throwing
an unexpected error every time -

    External WM_DESTROY received for QWidgetWindow

This commit fixes this error message
2021-12-11 21:13:15 +05:30
Srivats P
dbdeee2a6f Add option to recalculate cksums during pcap import
Recalculate cksum is now the default.

This behaviour change has been done to facilitate rewriting packet
fields post PCAP import using the new Find & Replace feature. Without
this any change in fields may cause incorrect checksums.

The earlier rationale for retaining the checksums in the PCAP file
during import was to ensure replayed packet was same as the one in the
PCAP file.

User now has a choice with this option.
2021-12-11 19:27:44 +05:30
Srivats P
366022552f Update pcap import options UI as per latest QtDesigner
There are some file format changes - all cosmetic
2021-12-11 18:11:53 +05:30
Srivats P
b8a0de377a Add find-replace preview as a TODO item 2021-12-11 16:18:38 +05:30
Srivats P
8333e5fbf1 Use QList::last instead of constLast for b/w compatibility
constLast was introduced in Qt5.6; Travis CI has older Qt
2021-12-11 16:00:57 +05:30
Srivats P
969e16aaf3 Fix IGMP/MLD group address find/replace
fieldData/setFieldData changed to work with uint in addition to string
2021-12-11 15:58:30 +05:30
Srivats P
4aedc61c8e Use uint64 for find/replace QVariant instead of string 2021-12-11 15:57:02 +05:30
Srivats P
f0c7ef50f7 Rename FieldEdit::setMask as FieldEdit::setMaskMode 2021-12-11 13:40:44 +05:30
Srivats P
975ce8093d Remove find-replace progress bar TODO as it's done 2021-12-11 13:01:31 +05:30
Srivats P
58d4ceb9c7 Ensure setFieldData return value for all protocols
Some protocol fields were not setting 'isOk' before returning it
2021-12-11 12:56:23 +05:30
Srivats P
fb91a094fc Show find-replace progress bar 2021-12-11 12:36:33 +05:30
Srivats P
a7aa93b9e9 Show affected field and stream count post replace 2021-12-09 10:14:47 +05:30
Srivats P
c1610f4c99 Derive field max from bitSize instead of saving it 2021-12-09 09:52:42 +05:30
Srivats P
dc7ac89c30 Verify find/replace mask works for all field types 2021-12-09 08:26:35 +05:30
Srivats P
4c6d8f35d6 Verify and fix Ip6Address type field edit 2021-12-08 21:36:39 +05:30
Srivats P
2eab3daa2f Set placeholder text for field edit types uint/mac 2021-12-06 21:14:38 +05:30
Srivats P
7cf9c91014 Verify and fix Ip4Address type field edit 2021-12-06 20:56:40 +05:30
Srivats P
9385b31bc5 Verify and fix MacAddress type field edit
Use QRegularExpression instead of QRegExp as the latter is deprecated in
Qt6
2021-12-05 12:09:02 +05:30
Srivats P
d3400f0897 Validate find-replace value based on field type
Only kUInt64 type has been verified for this commit.

Others are pending.
2021-12-04 12:17:37 +05:30
Srivats P
b60aad45d1 Implement find-replace logic for fields <= 64 bits 2021-12-03 19:01:32 +05:30
Srivats P
e19083ed3f Fleshed out some of the find-replace code 2021-11-27 22:13:55 +05:30
Srivats P
990c13e67a Add Find & Replace UI with skeletal code 2021-11-26 22:30:45 +05:30