Add window title param
This commit is contained in:
parent
e85b5bc0d4
commit
18b842c429
@ -3,9 +3,9 @@ from typing import Callable
|
|||||||
|
|
||||||
# QT6 non-window that presents a list of devices of which one can be connected
|
# QT6 non-window that presents a list of devices of which one can be connected
|
||||||
class ListChoice(QDialog):
|
class ListChoice(QDialog):
|
||||||
def __init__(self, items: dict[str, list[str]], parent=None):
|
def __init__(self, items: dict[str, list[str]], parent=None, window_title="Select Device"):
|
||||||
super().__init__(parent)
|
super().__init__(parent)
|
||||||
self.setWindowTitle("Select Device")
|
self.setWindowTitle(window_title)
|
||||||
self.setLayout(QVBoxLayout())
|
self.setLayout(QVBoxLayout())
|
||||||
self.layout().addWidget(QLabel("Select a device to connect to:"))
|
self.layout().addWidget(QLabel("Select a device to connect to:"))
|
||||||
self.device_list = QListWidget()
|
self.device_list = QListWidget()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user