(self)
| 1169 | |
| 1170 | @needsClient |
| 1171 | def OpenAddURIsToPlaylistDialog(self): |
| 1172 | URIsDialog = QtWidgets.QDialog() |
| 1173 | URIsDialog.setWindowTitle(getMessage("adduris-msgbox-label")) |
| 1174 | URIsLayout = QtWidgets.QGridLayout() |
| 1175 | URIsLabel = QtWidgets.QLabel(getMessage("adduris-msgbox-label")) |
| 1176 | URIsLayout.addWidget(URIsLabel, 0, 0, 1, 1) |
| 1177 | URIsTextbox = QtWidgets.QPlainTextEdit() |
| 1178 | URIsTextbox.setLineWrapMode(QtWidgets.QPlainTextEdit.NoWrap) |
| 1179 | URIsLayout.addWidget(URIsTextbox, 1, 0, 1, 1) |
| 1180 | URIsButtonBox = QtWidgets.QDialogButtonBox() |
| 1181 | URIsButtonBox.setOrientation(Qt.Horizontal) |
| 1182 | URIsButtonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel) |
| 1183 | URIsButtonBox.accepted.connect(URIsDialog.accept) |
| 1184 | URIsButtonBox.rejected.connect(URIsDialog.reject) |
| 1185 | URIsLayout.addWidget(URIsButtonBox, 2, 0, 1, 1) |
| 1186 | URIsDialog.setLayout(URIsLayout) |
| 1187 | URIsDialog.setModal(True) |
| 1188 | URIsDialog.setWindowFlags(URIsDialog.windowFlags() & ~Qt.WindowContextHelpButtonHint) |
| 1189 | URIsDialog.show() |
| 1190 | result = URIsDialog.exec_() |
| 1191 | if result == QtWidgets.QDialog.Accepted: |
| 1192 | URIsToAdd = utils.convertMultilineStringToList(URIsTextbox.toPlainText()) |
| 1193 | self.updatingPlaylist = True |
| 1194 | for URI in URIsToAdd: |
| 1195 | URI = URI.rstrip() |
| 1196 | URI = urllib.parse.unquote(URI) |
| 1197 | if URI != "": |
| 1198 | self.addStreamToPlaylist(URI) |
| 1199 | self.updatingPlaylist = False |
| 1200 | |
| 1201 | def openEditRoomsDialog(self): |
| 1202 | RoomsDialog = QtWidgets.QDialog() |
no test coverage detected