diff --git a/file.c b/file.c index ef5fd2a521..56b04291cf 100644 --- a/file.c +++ b/file.c @@ -845,7 +845,7 @@ cf_continue_tail(capture_file *cf, volatile int to_read, wtap_rec *rec, /* With the new packet list the first packet * isn't automatically selected. */ - if (!cf->current_frame) + if (!cf->current_frame && !packet_list_multi_select_active()) packet_list_select_first_row(); /* moving to the end of the packet list - if the user requested so and diff --git a/ui/qt/packet_list.cpp b/ui/qt/packet_list.cpp index 53b88ae23d..12c81d4861 100644 --- a/ui/qt/packet_list.cpp +++ b/ui/qt/packet_list.cpp @@ -203,6 +203,15 @@ packet_list_recent_write_all(FILE *rf) { gbl_cur_packet_list->writeRecent(rf); } +gboolean +packet_list_multi_select_active(void) +{ + if (gbl_cur_packet_list) { + return gbl_cur_packet_list->multiSelectActive(); + } + return FALSE; +} + #define MIN_COL_WIDTH_STR "MMMMMM" PacketList::PacketList(QWidget *parent) : diff --git a/ui/ws_ui_util.h b/ui/ws_ui_util.h index 80848bf7e8..ab720756d1 100644 --- a/ui/ws_ui_util.h +++ b/ui/ws_ui_util.h @@ -68,6 +68,7 @@ void packet_list_select_first_row(void); void packet_list_moveto_end(void); gboolean packet_list_select_row_from_data(frame_data *fdata_needle); void packet_list_resize_column(gint col); +gboolean packet_list_multi_select_active(void); /* XXX - Yes this isn't the best place, but they are used by file_dlg_win32.c, which is supposed to be GUI independent, but has lots of GTK leanings. But if you put these in a GTK UI