From 1970c6029cc293fd86ca6e05867a0f61683dd1e8 Mon Sep 17 00:00:00 2001 From: Et0h Date: Thu, 2 Jun 2016 20:10:07 +0100 Subject: [PATCH] Make AddURI and setMediaDir dialogs modal so they can't be lost --- syncplay/ui/gui.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/syncplay/ui/gui.py b/syncplay/ui/gui.py index 909119e..4d776bd 100644 --- a/syncplay/ui/gui.py +++ b/syncplay/ui/gui.py @@ -794,6 +794,7 @@ class MainWindow(QtGui.QMainWindow): URIsButtonBox.rejected.connect(URIsDialog.reject) URIsLayout.addWidget(URIsButtonBox, 2, 0, 1, 1) URIsDialog.setLayout(URIsLayout) + URIsDialog.setModal(True) URIsDialog.show() result = URIsDialog.exec_() if result == QtGui.QDialog.Accepted: @@ -824,6 +825,7 @@ class MainWindow(QtGui.QMainWindow): MediaDirectoriesAddFolderButton.pressed.connect(lambda: self.openAddMediaDirectoryDialog(MediaDirectoriesTextbox, MediaDirectoriesDialog)) MediaDirectoriesLayout.addWidget(MediaDirectoriesAddFolderButton, 1, 1, 1, 1, Qt.AlignTop) MediaDirectoriesDialog.setLayout(MediaDirectoriesLayout) + MediaDirectoriesDialog.setModal(True) MediaDirectoriesDialog.show() result = MediaDirectoriesDialog.exec_() if result == QtGui.QDialog.Accepted: