Kerberos: add kerberos_inject_longterm_key() helper function
[wireshark-sm.git] / ui / qt / export_pdu_dialog.cpp
blob27b778429401b45f6d44c9edfb75ef39426458cf
1 /* export_pdu_dialog.cpp
2 * Dialog for exporting PDUs to file
4 * Wireshark - Network traffic analyzer
5 * By Gerald Combs <gerald@wireshark.org>
6 * Copyright 1998 Gerald Combs
8 * SPDX-License-Identifier: GPL-2.0-or-later
9 */
11 #include "config.h"
13 #include "export_pdu_dialog.h"
14 #include <ui_export_pdu_dialog.h>
16 #include <epan/tap.h>
17 #include <epan/exported_pdu.h>
19 #include "ui/export_pdu_ui_utils.h"
20 #include "ui/capture_globals.h"
22 #include "main_application.h"
24 ExportPDUDialog::ExportPDUDialog(QWidget *parent) :
25 QDialog(parent),
26 ui(new Ui::ExportPDUDialog)
28 GSList *tap_name_list;
30 ui->setupUi(this);
32 setWindowTitle(mainApp->windowTitleString(tr("Export PDUs")));
34 for (tap_name_list = get_export_pdu_tap_list(); tap_name_list; tap_name_list = g_slist_next(tap_name_list)) {
35 if (export_pdu_tap_get_encap((const char*)tap_name_list->data) == WTAP_ENCAP_WIRESHARK_UPPER_PDU) {
36 ui->comboBox->addItem((const char*)(tap_name_list->data));
41 void ExportPDUDialog::on_buttonBox_accepted()
43 const QByteArray& filter = ui->displayFilterLineEdit->text().toUtf8();
44 const QByteArray& tap_name = ui->comboBox->currentText().toUtf8();
46 do_export_pdu(filter.constData(), global_capture_opts.temp_dir, tap_name.constData());
49 void ExportPDUDialog::on_buttonBox_helpRequested()
51 mainApp->helpTopicAction(HELP_EXPORT_PDUS_DIALOG);
54 ExportPDUDialog::~ExportPDUDialog()
56 delete ui;