mirror of
https://github.com/dcs-liberation/dcs_liberation.git
synced 2025-11-10 14:22:26 +00:00
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.
15 lines
459 B
Python
15 lines
459 B
Python
from PySide6.QtWidgets import QGridLayout, QLabel
|
|
|
|
from game.ato import Flight
|
|
from .propertyselector import PropertySelector
|
|
|
|
|
|
class PropertyEditor(QGridLayout):
|
|
def __init__(self, flight: Flight) -> None:
|
|
super().__init__()
|
|
self.flight = flight
|
|
|
|
for row, prop in enumerate(flight.unit_type.iter_props()):
|
|
self.addWidget(QLabel(prop.id), row, 0)
|
|
self.addWidget(PropertySelector(self.flight, prop), row, 1)
|