aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt/export_dissection_dialog.cpp
diff options
context:
space:
mode:
authorRoland Knall <rknall@gmail.com>2019-11-12 16:39:19 +0100
committerRoland Knall <rknall@gmail.com>2019-11-17 12:20:29 +0000
commitb3f240dbf8c5e24cf420e977d8544c4abb40c80e (patch)
treec783c4f210f09ed7c8ab227e9923953a6d8872e0 /ui/qt/export_dissection_dialog.cpp
parent7d2e3fa8f5115e8cdddd5ea7a05797151a3965e7 (diff)
Qt: Multiselection in PacketList
This implements multi-selection for the PacketList. It allows multiple lines to be selected, and either drag/drop them to a text editor or use Ctrl/Cmd+C to copy the content to a clipboard. Opening the context menu disables the selection, and it does not change the underlying currently selection. This is done on purpose, as multi-selection is a copy-task only functionality at this point Export & Print work as expected, exporting just the selected items. Same goes for the copy menu, which has the additional entries for copying the list elements Bug: 14612 Change-Id: I77960aa1ab1d172a21abfa469baac0cd57f9f9d9 Reviewed-on: https://code.wireshark.org/review/35073 Petri-Dish: Roland Knall <rknall@gmail.com> Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot Reviewed-by: Roland Knall <rknall@gmail.com>
Diffstat (limited to 'ui/qt/export_dissection_dialog.cpp')
-rw-r--r--ui/qt/export_dissection_dialog.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/ui/qt/export_dissection_dialog.cpp b/ui/qt/export_dissection_dialog.cpp
index e0afdfbe94..507d4c75e5 100644
--- a/ui/qt/export_dissection_dialog.cpp
+++ b/ui/qt/export_dissection_dialog.cpp
@@ -46,7 +46,7 @@ static const QStringList export_extensions = QStringList()
#endif
-ExportDissectionDialog::ExportDissectionDialog(QWidget *parent, capture_file *cap_file, export_type_e export_type):
+ExportDissectionDialog::ExportDissectionDialog(QWidget *parent, capture_file *cap_file, export_type_e export_type, QString selRange):
QFileDialog(parent),
export_type_(export_type),
cap_file_(cap_file)
@@ -119,7 +119,7 @@ ExportDissectionDialog::ExportDissectionDialog(QWidget *parent, capture_file *ca
/* Default to displayed packets */
print_args_.range.process_filtered = TRUE;
- packet_range_group_box_.initRange(&print_args_.range);
+ packet_range_group_box_.initRange(&print_args_.range, selRange);
h_box->addWidget(&packet_range_group_box_);
h_box->addWidget(&packet_format_group_box_, 0, Qt::AlignTop);