mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Load map.js explicitly from canvas.html.
Without this it's hard to get to map.js in the debug tools since Chrome doesn't know about the anonymous js. Probably improves logging too.
This commit is contained in:
parent
e6e31fd234
commit
de9651533f
@ -167,11 +167,6 @@ class LeafletMap(QWebEngineView, LiberationMap):
|
||||
)
|
||||
self.setPage(self.page)
|
||||
|
||||
self.loadFinished.connect(self.load_finished)
|
||||
|
||||
def load_finished(self) -> None:
|
||||
self.page.runJavaScript(Path("resources/ui/map/map.js").read_text())
|
||||
|
||||
def set_game(self, game: Optional[Game]) -> None:
|
||||
if game is None:
|
||||
self.map_model.clear()
|
||||
|
||||
@ -24,6 +24,7 @@
|
||||
integrity="sha384-XAr1poM2RCR9/QQFki7ylrGSdmvYE0NuHghuRuxb/k9zJQA53y6qR5te5jJRZlcL"
|
||||
crossorigin="">
|
||||
</script>
|
||||
<script src="map.js" defer="defer"></script>
|
||||
<style>
|
||||
body { padding: 0; margin: 0; }
|
||||
html, body, #map { height: 100%; }
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user