diff options
author | Jirka Novak <j.novak@netsystem.cz> | 2021-01-06 23:49:36 +0100 |
---|---|---|
committer | AndersBroman <a.broman58@gmail.com> | 2021-01-07 09:56:18 +0000 |
commit | 1d43b2a3aa50359e002c2016024167cb8c7fa365 (patch) | |
tree | ec598bc497c09fe1ed4b09b9f6c7c53c488a13df /ui/qt/rtp_stream_dialog.cpp | |
parent | 55075f6e8dce1093d2be50ce5b84bf05a2f07e8c (diff) |
Telecom dialogs: Fixed issues during capture file closing
When capture file is closing/closed, dialogs do not disable buttons which
can't work without capture file. Patch fixes it.
Diffstat (limited to 'ui/qt/rtp_stream_dialog.cpp')
-rw-r--r-- | ui/qt/rtp_stream_dialog.cpp | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/ui/qt/rtp_stream_dialog.cpp b/ui/qt/rtp_stream_dialog.cpp index a480abdced..2fe278a282 100644 --- a/ui/qt/rtp_stream_dialog.cpp +++ b/ui/qt/rtp_stream_dialog.cpp @@ -487,7 +487,7 @@ void RtpStreamDialog::updateWidgets() prepare_button_->setEnabled(enable); export_button_->setEnabled(enable); copy_button_->setEnabled(has_data); - analyze_button_->setEnabled(selected); + analyze_button_->setEnabled(enable); ui->actionFindReverse->setEnabled(enable); ui->actionGoToSetup->setEnabled(enable); @@ -496,10 +496,10 @@ void RtpStreamDialog::updateWidgets() ui->actionExportAsRtpDump->setEnabled(enable); ui->actionCopyAsCsv->setEnabled(has_data); ui->actionCopyAsYaml->setEnabled(has_data); - ui->actionAnalyze->setEnabled(selected); + ui->actionAnalyze->setEnabled(enable); #if defined(QT_MULTIMEDIA_LIB) - player_button_->setEnabled(selected); + player_button_->setEnabled(enable); #else player_button_->setEnabled(false); player_button_->setText(tr("No Audio")); @@ -543,12 +543,21 @@ QList<QVariant> RtpStreamDialog::streamRowData(int row) const void RtpStreamDialog::captureFileClosing() { + ui->todCheckBox->setEnabled(false); + ui->displayFilterCheckBox->setEnabled(false); + remove_tap_listener_rtpstream(&tapinfo_); + WiresharkDialog::captureFileClosing(); } void RtpStreamDialog::showStreamMenu(QPoint pos) { + ui->actionGoToSetup->setEnabled(!file_closed_); + ui->actionMarkPackets->setEnabled(!file_closed_); + ui->actionPrepareFilter->setEnabled(!file_closed_); + ui->actionExportAsRtpDump->setEnabled(!file_closed_); + ui->actionAnalyze->setEnabled(!file_closed_); ctx_menu_.popup(ui->streamTreeWidget->viewport()->mapToGlobal(pos)); } |