Lgndr: Update test get_boolean_choice to the arguments of its counterpart
This commit is contained in:
parent
5c1ff81370
commit
654f734975
|
@ -3,8 +3,11 @@ import logging
|
||||||
from PyQt5.QtWidgets import QMessageBox, QLabel
|
from PyQt5.QtWidgets import QMessageBox, QLabel
|
||||||
|
|
||||||
|
|
||||||
def get_boolean_choice(a0):
|
def get_boolean_choice(prompt, default=True):
|
||||||
choice = QMessageBox.question(None, "Import DLCs?", a0)
|
choice = QMessageBox.question(
|
||||||
|
None, "Import DLCs?", prompt,
|
||||||
|
defaultButton=QMessageBox.Yes if default else QMessageBox.No
|
||||||
|
)
|
||||||
return True if choice == QMessageBox.StandardButton.Yes else False
|
return True if choice == QMessageBox.StandardButton.Yes else False
|
||||||
|
|
||||||
|
|
||||||
|
@ -18,4 +21,4 @@ class UILogHandler(logging.Handler):
|
||||||
self.widget = dest
|
self.widget = dest
|
||||||
|
|
||||||
def emit(self, record: logging.LogRecord) -> None:
|
def emit(self, record: logging.LogRecord) -> None:
|
||||||
self.widget.setText(record.getMessage())
|
self.widget.setText(record.getMessage())
|
||||||
|
|
Loading…
Reference in a new issue