mirror of
https://github.com/dcs-liberation/dcs_liberation.git
synced 2025-11-10 14:22:26 +00:00
Update to PySide6.
It sounds like PySide2 will not be moving to Python 3.11, so we're stuck on 3.10 without this. Upgrading to a newer Qt also fixes some high DPI bugs (the file browser dialog for save/load is no longer tiny on 4k). https://github.com/pyinstaller/pyinstaller/issues/5414 previously blocked this, but the bug appears to be fixed now.
This commit is contained in:
@@ -3,12 +3,9 @@ from __future__ import annotations
|
||||
import logging
|
||||
from pathlib import Path
|
||||
|
||||
from PySide2.QtCore import QUrl
|
||||
from PySide2.QtWebEngineWidgets import (
|
||||
QWebEnginePage,
|
||||
QWebEngineSettings,
|
||||
QWebEngineView,
|
||||
)
|
||||
from PySide6.QtCore import QUrl
|
||||
from PySide6.QtWebEngineCore import QWebEnginePage, QWebEngineSettings
|
||||
from PySide6.QtWebEngineWidgets import QWebEngineView
|
||||
|
||||
from game.server.settings import ServerSettings
|
||||
from qt_ui.models import GameModel
|
||||
@@ -40,7 +37,7 @@ class QLiberationMap(QWebEngineView):
|
||||
# Required to allow "cross-origin" access from file:// scoped canvas.html to the
|
||||
# localhost HTTP backend.
|
||||
self.page.settings().setAttribute(
|
||||
QWebEngineSettings.LocalContentCanAccessRemoteUrls, True
|
||||
QWebEngineSettings.WebAttribute.LocalContentCanAccessRemoteUrls, True
|
||||
)
|
||||
|
||||
if dev:
|
||||
|
||||
Reference in New Issue
Block a user