Qt: Unparent NetPlay dialog from main window

This should make the NetPlay dialog appear as a separate window in the taskbar on most systems, which makes more sense than a parented dialog as the user will leave it open for an extended period.
This commit is contained in:
Techjar 2018-07-04 16:41:56 -04:00
parent fd83937987
commit f620128dac
3 changed files with 5 additions and 2 deletions

View file

@ -156,6 +156,7 @@ MainWindow::MainWindow(std::unique_ptr<BootParameters> boot_parameters) : QMainW
MainWindow::~MainWindow()
{
m_render_widget->deleteLater();
m_netplay_dialog->deleteLater();
ShutdownControllers();
QSettings& settings = Settings::GetQSettings();
@ -1037,7 +1038,7 @@ void MainWindow::BootWiiSystemMenu()
void MainWindow::NetPlayInit()
{
m_netplay_setup_dialog = new NetPlaySetupDialog(this);
m_netplay_dialog = new NetPlayDialog(this);
m_netplay_dialog = new NetPlayDialog;
connect(m_netplay_dialog, &NetPlayDialog::Boot, this,
[this](const QString& path) { StartGame(path); });