Show the status of each flight in the UI.

https://github.com/dcs-liberation/dcs_liberation/issues/1704
This commit is contained in:
Dan Albert
2021-11-07 01:24:49 -07:00
parent 30cfd8a769
commit d31f0e22e3
15 changed files with 99 additions and 24 deletions

View File

@@ -1,7 +1,7 @@
from __future__ import annotations
import logging
from datetime import datetime
from datetime import datetime, timedelta
from pathlib import Path
from typing import Callable, Optional, TYPE_CHECKING
@@ -40,6 +40,12 @@ class SimController(QObject):
return None
return self.game_loop.current_time_in_sim
@property
def elapsed_time(self) -> timedelta:
if self.game_loop is None:
return timedelta()
return self.game_loop.elapsed_time
def set_game(self, game: Optional[Game]) -> None:
self.recreate_game_loop(game)
self.sim_speed_reset.emit(SimSpeedSetting.PAUSED)