From 12b30eb2ed6bf715eb47d55abe59bd18cff0f58e Mon Sep 17 00:00:00 2001 From: fourtf Date: Sun, 28 Jan 2018 18:05:01 +0100 Subject: [PATCH] minor changes to the pr --- src/widgets/qualitypopup.cpp | 7 ++++--- src/widgets/qualitypopup.hpp | 5 +---- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/src/widgets/qualitypopup.cpp b/src/widgets/qualitypopup.cpp index 16c6c75ff..73735f3aa 100644 --- a/src/widgets/qualitypopup.cpp +++ b/src/widgets/qualitypopup.cpp @@ -12,7 +12,6 @@ QualityPopup::QualityPopup(const QString &channel, const QString &path, QStringL { this->ui.okButton.setText("OK"); this->ui.cancelButton.setText("Cancel"); - this->setAttribute(Qt::WA_DeleteOnClose, true); QObject::connect(&this->ui.okButton, &QPushButton::clicked, this, &QualityPopup::okButtonClicked); @@ -36,6 +35,8 @@ void QualityPopup::showDialog(const QString &channel, const QString &path, QStri { QualityPopup *instance = new QualityPopup(channel, path, options); + instance->setAttribute(Qt::WA_DeleteOnClose, true); + instance->show(); instance->activateWindow(); instance->raise(); @@ -45,8 +46,8 @@ void QualityPopup::showDialog(const QString &channel, const QString &path, QStri void QualityPopup::okButtonClicked() { singletons::SettingManager &settings = singletons::SettingManager::getInstance(); - QProcess::startDetached(this->path, - {"twitch.tv/" + this->channel, this->ui.selector.currentText(), settings.streamlinkOpts}); + QProcess::startDetached(this->path, {"twitch.tv/" + this->channel, + this->ui.selector.currentText(), settings.streamlinkOpts}); this->close(); } diff --git a/src/widgets/qualitypopup.hpp b/src/widgets/qualitypopup.hpp index 9353208c2..7875dafe0 100644 --- a/src/widgets/qualitypopup.hpp +++ b/src/widgets/qualitypopup.hpp @@ -1,5 +1,4 @@ -#ifndef QUALITYPOPUP_H -#define QUALITYPOPUP_H +#pragma once #include #include @@ -39,5 +38,3 @@ private: } // namespace widgets } // namespace chatterino - -#endif // QUALITYPOPUP_H