summaryrefslogtreecommitdiffstats
path: root/src/engine
diff options
context:
space:
mode:
authorDaniel Schürmann <daschuer@mixxx.org>2021-02-02 13:33:26 +0100
committerDaniel Schürmann <daschuer@mixxx.org>2021-02-02 13:33:26 +0100
commit0fd04297eef7d9f442d0292c85fd581cf219c837 (patch)
treec3e4aabfb2d23bea32dea27dd81c176bd11644d0 /src/engine
parent3968d81ecce212189b4858680454174470754d96 (diff)
Fix second pop up in case of encoder issues during broadcasting.
Diffstat (limited to 'src/engine')
-rw-r--r--src/engine/sidechain/shoutconnection.cpp26
1 files changed, 12 insertions, 14 deletions
diff --git a/src/engine/sidechain/shoutconnection.cpp b/src/engine/sidechain/shoutconnection.cpp
index 1ff156b73f..8c7807704b 100644
--- a/src/engine/sidechain/shoutconnection.cpp
+++ b/src/engine/sidechain/shoutconnection.cpp
@@ -466,24 +466,20 @@ void ShoutConnection::updateFromPreferences() {
// TODO(XXX): Use mixxx::audio::SampleRate instead of int in initEncoder
if (ret < 0) {
- ErrorDialogProperties* props = ErrorDialogHandler::instance()->newDialogProperties();
- props->setType(DLG_WARNING);
- props->setTitle(pBroadcastSettings->getFormat() + QChar(' ') +
- QObject::tr(" encoder failure"));
- if (userErrorMsg.isEmpty()) {
- QString userErrorMsg = QObject::tr(
- "Failed to apply the selected settings.");
- }
- props->setText(userErrorMsg);
- ErrorDialogHandler::instance()->requestErrorDialog(props);
-
// delete m_encoder calls write() make sure it will be exit early
DEBUG_ASSERT(m_iShoutStatus != SHOUTERR_CONNECTED);
m_encoder.reset();
setState(NETWORKSTREAMWORKER_STATE_ERROR);
- m_lastErrorStr = "Encoder error";
+ m_lastErrorStr = pBroadcastSettings->getFormat() + QChar(' ') +
+ QObject::tr(" encoder failure") + QChar('\n');
+ if (userErrorMsg.isEmpty()) {
+ m_lastErrorStr.append(QObject::tr(
+ "Failed to apply the selected settings."));
+ } else {
+ m_lastErrorStr.append(userErrorMsg);
+ }
return;
}
setState(NETWORKSTREAMWORKER_STATE_READY);
@@ -1010,8 +1006,10 @@ void ShoutConnection::run() {
if (!processConnect()) {
errorDialog(tr("Can't connect to streaming server"),
- m_lastErrorStr + "\n" +
- tr("Please check your connection to the Internet and verify that your username and password are correct."));
+ m_lastErrorStr + "\n\n" +
+ tr("Please check your connection to the Internet and "
+ "verify that your username and password are "
+ "correct."));
return;
}