mainbar: fix build without libsigrokdecode
[pulseview.git] / pv / toolbars / mainbar.cpp
index 6d225369dda8516563160dec278167b63c6c3c9f..e517ff78c5cd594f804b55ef4e464f5e9d764c06 100644 (file)
@@ -35,7 +35,6 @@
 
 #include <boost/algorithm/string/join.hpp>
 
-#include <pv/data/decodesignal.hpp>
 #include <pv/devicemanager.hpp>
 #include <pv/devices/hardwaredevice.hpp>
 #include <pv/devices/inputfile.hpp>
@@ -52,6 +51,7 @@
 #include <pv/widgets/importmenu.hpp>
 #ifdef ENABLE_DECODE
 #include <pv/widgets/decodermenu.hpp>
+#include <pv/data/decodesignal.hpp>
 #endif
 
 #include <libsigrokcxx/libsigrokcxx.hpp>
@@ -384,7 +384,7 @@ void MainBar::update_sample_rate_selector_value()
                sample_rate_.set_value(samplerate);
                updating_sample_rate_ = false;
        } catch (Error& error) {
-               qDebug() << tr("Failed to get value of sample rate:") << error.what();
+               qDebug() << tr("Failed to get sample rate:") << error.what();
        }
 }
 
@@ -556,8 +556,7 @@ void MainBar::commit_sample_count()
 void MainBar::show_session_error(const QString text, const QString info_text)
 {
        QMessageBox msg(this);
-       msg.setText(text);
-       msg.setInformativeText(info_text);
+       msg.setText(text + "\n\n" + info_text);
        msg.setStandardButtons(QMessageBox::Ok);
        msg.setIcon(QMessageBox::Warning);
        msg.exec();