If you want to terminate the connection when the window closes then do it in the closeEvent method: class MainWindow(QtWidgets.
確定! 回上一頁