From 5cdc4a8f4f573541adc7dc4ada5ede38af603887 Mon Sep 17 00:00:00 2001 From: Sergey Palcheh Date: Mon, 4 Aug 2025 12:35:29 +0600 Subject: [PATCH] added blocking of license agreement confirmation --- winehelper_gui.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/winehelper_gui.py b/winehelper_gui.py index f6d7dc7..7202b73 100644 --- a/winehelper_gui.py +++ b/winehelper_gui.py @@ -1256,6 +1256,8 @@ class WineHelperGUI(QMainWindow): license_page = QWidget() license_layout = QVBoxLayout(license_page) + license_found = False + license_text = QTextBrowser() # Получаем текст лицензионного соглашения из файла @@ -1272,6 +1274,7 @@ class WineHelperGUI(QMainWindow): license_text.setHtml(f"""
{escaped_license_content}
""") + license_found = True except (FileNotFoundError, TypeError): license_text.setHtml(f'

Лицензионные соглашения

Не удалось загрузить файл лицензионного соглашения по пути:
{Var.LICENSE_AGREEMENT_FILE}

') except Exception as e: @@ -1325,6 +1328,9 @@ class WineHelperGUI(QMainWindow): lambda state: self.btn_continue.setEnabled(state == Qt.Checked) ) + if not license_found: + self.license_checkbox.setEnabled(False) + self.install_dialog.show() def _prepare_installation(self):