Files
qt-migration-legatus/qt6-after/qt6-migrated-legatus/Lts/Tools/ArAssetsV3_Qatar/src/Tracking.ts
T
torsten d5c13033e2 Session 022: Migrate Lts/Tools (72 submodules) to Qt6
- Copied complete Lts/Tools directory from qt5-before to qt6-after
- Updated 32 CMakeLists.txt files (Qt5:: → Qt6::)
- Tools subdirectory already included in parent Lts/CMakeLists.txt
- All 72 tool submodules now present in qt6-migrated-legatus
- Includes: Adler, ArAssets, ConfigX, DBAdministration, DBUpdate,
  DdsView, InfrastructureManagement, and 67 more tools
- C++17 standard (RTI 7.7.0 compatibility maintained)
- Tests deferred until final validation phase

Migration progress:
✅ Lts/Application (68 files)
✅ Lts/DDS (verified Qt6-ready)
✅ Lts/Plugins (60 submodules, verified)
✅ Lts/Projects (5 submodules, verified)
✅ Lts/Proxies (13 submodules, verified)
✅ Lts/Services (47 submodules, verified)
✅ Lts/Tools (72 submodules, copied + CMake updated)
✅ Lts/Viewer (LtsFileDialog, LtsReportDisplay, SituationMap)
🟡 TetraIF (partial)
🟡 Z (partial: nglwidgets, QtSingleApplication, qsql_informix, WMS_Interface)
2026-08-25 14:07:20 +02:00

63 lines
2.3 KiB
TypeScript
Executable File

import L, { LatLng } from "leaflet";
export default class Tracking
{
map: L.Map;
popup = L.popup();
msg: string;
participant: L.Marker;
popupLocation: L.LatLng;
popupContent: HTMLElement;
constructor(input: L.Map, obj: string, marker: L.Marker){
this.map = input;
var viewPos = new L.LatLng(53.0528064472226, 8.89412999153137);
this.msg = obj;
this.participant = marker;
var runIcon = new L.Icon({
iconUrl: 'img/marker-run.png',
shadowUrl: 'img/marker-shadow.png',
iconSize: [25, 41],
iconAnchor: [12, 41],
popupAnchor: [1, 50],
shadowSize: [0, 0]
});
var participant = new L.Marker(viewPos, {icon: runIcon}).on('click', this.onMarkerClick);
this.popupLocation = new LatLng(0,0);
this.popupContent = new HTMLElement();
participant.addTo(this.map);
}
onMarkerClick()
{
this.popup
.setLatLng(this.popupLocation)
.setContent(this.popupContent)
.openOn(this.map);
}
start()
{
console.log('<p class="message">Received: '+this.msg);
var newjobj = JSON.parse(this.msg);
console.log(newjobj);
if(newjobj.data.header.equipmentNumber == Number((<HTMLInputElement>document.getElementById("equipmentNumber")).value)){
var jsonConv = '{"1": "NaN", "lat": ' + newjobj.data.geoPosition.lat/(Math.PI/180) + ', "lng": ' + newjobj.data.geoPosition.lon/(Math.PI/180) + '}';
var convlatlng = JSON.parse(jsonConv);
this.participant.setLatLng( [convlatlng.lat, convlatlng.lng]);
var markerlatlng = convlatlng
markerlatlng.lat= convlatlng.lat+0.00002;
this.popupLocation = markerlatlng;
this.popupContent = document.createElement("<center>EquipmentNr: " + newjobj.data.header.equipmentNumber + "<br>"
+ "BuildingID: " + newjobj.data.opsPosition.moutObjectId + "<br>"
+ "RoomID: " + newjobj.data.opsPosition.moutRoomId + "</center>");
this.popup
.setLatLng(this.popupLocation)
.setContent(this.popupContent)
.openOn(this.map);
}
}
}