walterroach d7e48662e0 Add custom flight names
Mildly breaks save compat with 2.3; All existing flight dialogs will be
broken, passing the turn or recreating all the flights in the UI will
allow you to continue
2020-12-28 10:52:25 -06:00

17 lines
464 B
Python

from PySide2.QtWidgets import QGroupBox, QHBoxLayout, QLabel
from gen.flights.flight import Flight
class QFlightCustomName(QGroupBox):
def __init__(self, flight: Flight):
super(QFlightCustomName, self).__init__()
self.flight = flight
self.layout = QHBoxLayout()
self.custom_name_label = QLabel(f"Custom Name: {flight.custom_name}")
self.layout.addWidget(self.custom_name_label)
self.setLayout(self.layout)