X-Git-Url: http://git.code-monkey.de/?a=blobdiff_plain;f=pv%2Fmainwindow.cpp;h=dc5f981f7b3a5207ab0bc777e1656e292d12784b;hb=a915c6a33eb66a170e9cf1dd6c76980def838b14;hp=aa06601c3824a6c74eab2ad74b33e3a3155040aa;hpb=535554a4d1855b6c15bf20746b3aafd8c53a6ca9;p=pulseview.git diff --git a/pv/mainwindow.cpp b/pv/mainwindow.cpp index aa06601..dc5f981 100644 --- a/pv/mainwindow.cpp +++ b/pv/mainwindow.cpp @@ -391,8 +391,16 @@ void MainWindow::add_decoder(QObject *action) const std::vector< boost::shared_ptr > &sigs = _session.get_signals(); - dialogs::Decoder dlg(this, dec, sigs); - dlg.exec(); + GHashTable *const options = g_hash_table_new_full(g_str_hash, + g_str_equal, g_free, (GDestroyNotify)g_variant_unref); + + dialogs::Decoder dlg(this, dec, sigs, options); + if(dlg.exec() != QDialog::Accepted) { + g_hash_table_destroy(options); + return; + } + + _session.add_decoder(dec, dlg.get_probes(), options); } void MainWindow::run_stop()