1
0
Fork 0
Commit graph

10987 commits

Author SHA1 Message Date
James Turner
9326c88f9b Move Qt root path variable to top-level CMakeList 2020-06-10 17:59:09 +01:00
James Turner
c1afb053a1 Fix flight-plan cloning with approach transitions 2020-06-10 17:58:31 +01:00
James Turner
bce6b56c8d Remove use of QQ.Window / PopupTracker
Overlay menus work better than native popups for most use-cases, and
simplify integration (no window focus changes). Switch the remaining
menus to always use the overlay system

As part of this, fix how Overlay positions are adjusted, to avoid
the ugly zero-interval timer.
2020-06-10 16:54:27 +01:00
James Turner
aedaf798c0 Launcher: add key shortcut for Fly!
Ctrl-F, since we don’t have a find function.

Requested by Richard, and easy to add :)
2020-06-09 14:53:43 +01:00
Julian Smith
43130aa581 Fixed splash download statistics to use 'B' for bytes rather than 'b'.
'b' usually means bits.
2020-06-09 10:43:15 +01:00
James Turner
6278e74e4b Fix MSVC build: include <atomic>
(Weirdly, only needed with some MSVC versions…)
2020-06-09 08:43:14 +01:00
James Turner
2574783656 ATC: Fix crash with missing traffic ID
https://sourceforge.net/p/flightgear/codetickets/2254/
2020-06-08 22:44:52 +01:00
James Turner
32ff21c1df UI: support OSG multi-threading modes, partially
Requires private header, so might need an additional package installed
on some Unixes.
2020-06-08 22:44:52 +01:00
James Turner
2ca06d5b69 Launcher: move PNGs to assets/ subdir 2020-06-05 22:16:02 +01:00
James Turner
3cd3ad465e Add Qt dialog state controller
Allow standard control of drill-down dialogs (with back / forward
navigation)
2020-06-05 22:09:03 +01:00
James Turner
faa070307d Add property Qt item-model
Allows exposing a set of property nodes as a model in combo boxes,
lists, etc.
2020-06-05 22:09:03 +01:00
James Turner
c2c3bc17f6 Expose child-props to QML binding class 2020-06-05 22:09:03 +01:00
Julian Smith
edb5be38ee Multiplayer replay: add support to fgtape recordings. improved replay behaviour.
Fgtape:

    If multipayer replay is active we write multiplayer packet information to
    fgtape files. We also add /sim/replay/multiplayer to the properties written
    to fgtape file so at load time we knows whether to expect multiplayer
    packets.

    New builds of fg can load and replay old recordings.

    It is expected (but has not been tested) that old builds of fg will be able
    to read new fgtape recordings where /sim/replay/multiplayer was unset or
    false (currently the default).

    Old builds of fg will not be able to load fgtape recordings that include
    multiplayer data.

Avoid incorrect removal of multiplayer aircraft when replaying:

    We now clear multiplayer motion history when we jump forwards or backwards
    during replay. This ensures that multiplayer code doesn't remove
    multiplayer aircraft because of inconsistent-looking time stamps.

    We preserve some multiplay information when purging recorded information
    to save space. This ensures that when replaying we get frequent enough
    packets to avoid the multiplayer code thinking that multiplayer aircraft
    have disappeared.
2020-06-05 21:21:14 +01:00
Julian Smith
4de00657c9 Multiplayer replay: added properties showing memory usage info. 2020-06-05 21:21:14 +01:00
Julian Smith
e7b1f3f52e Multiplayer replay: new, support for replaying multiplayer aircraft as well as the user's aircraft.
At the moment this only works for live replays - we don't (yet) write the
multiplayer information to fgtape files.

Enable with:
    --prop:bool:/sim/replay/multiplayer=true

This works by copying all raw multiplayer packets into a buffer in
FGMultiplayMgr. Each time it is called, FGFlightRecorder::capture() moves all
the available packet from this buffer into its FGReplayData. Thus we store
roughly syncronised multiplayer packets along with the user aircraft's detailed
replay properties.

When replaying, FGFlightRecorder pushes packets into a buffer in
FGMultiplayMgr, which are used instead of live multiplayer packets. [Actually
when replaying FGMultiplayMgr still reads live packets in order to handle live
chat messages, and ignores chat messages from FGFlightRecorder.]
2020-06-05 21:21:14 +01:00
James Turner
0015744486 Nasal unit-testing feedback from Henning 2020-06-05 21:00:59 +01:00
James Turner
033a53f1d7 Add missing code to previous commit :) 2020-06-05 20:49:05 +01:00
James Turner
a9e5a27e55 UI handling tweaks
- add class to handle top-level windows
- remove requirement to use custom graphics-window
- order alongside PUI UI
2020-06-05 17:54:27 +01:00
James Turner
6beeea2bd5 Nasal flight-plans: allow clearing transitions
When nil is set on the _trans members, clear the transition value
internally. Also fix an error message.
2020-06-04 17:54:13 +01:00
James Turner
023fbe35ea Tweaks to avoid a crash when asking for FGData path
exit(-1) early in startup seems to cause QApplication to be cleaned
up in a weird way
2020-06-04 17:43:27 +01:00
James Turner
9cc9a8a197 Add ‘makesingleshot’ helper to Nasal.
Makes a timer object, but set to single shot mode and starts it.
2020-06-01 11:16:37 +01:00
James Turner
26b0148747 Preserve developer-mode on reset
Thanks to Henning for pointing out problem.
2020-06-01 11:15:45 +01:00
James Turner
13bb1adf54 Better fix for orientation nodes init
(Avoid the chance that we overwrite a value set earlier)
2020-05-31 12:24:36 +01:00
James Turner
c0d347859f Ensure various properties have a value on start.
Ensure /orientation/heading-magnetic-deg, etc have a type of double
immediately. Showed up as a bug in the SenecaII, since the property
is created but has NIL value until the first update() call.
2020-05-31 12:18:07 +01:00
James Turner
03563a1601 Fix DME intercept handling in route/GPS
Both the route-path cade and the RNAV code were using some bad logic
to compute the intersection point. All fixed now, but requires a
new helper in Simgear.
2020-05-30 15:59:07 +01:00
James Turner
e51a0c55b5 Fly-by support for Radial intercepts
In the common case, avoid an overshoot when doing radial
intercepts.
2020-05-30 15:59:07 +01:00
James Turner
6bb1478067 GPS fly-by support
Remove the non-functional turn-anticipation code from the GPS, and
enable fly-by mode in (some of the) RNAV controllers: initially the
leg controller.

The new config property is gps/config/enable-fly-by, defaults to off
for compatibility.
2020-05-30 15:59:07 +01:00
James Turner
58d7454976 Explicit support for approach transitions
Make the handling of approach transitions consistent with SID and STAR
transitions, including the Nasal API. Add some tests to cover the
new features.
2020-05-27 21:44:59 +01:00
James Turner
55ce199535 Fixes for cloning FPs with procedures 2020-05-27 16:09:18 +01:00
Bertrand Coconnier
9ed2406878 [JSBSim] Actuator <lag> elements can now be specified by either a value or a property.
Thanks to Sean McLeod for the patch.
2020-05-27 15:48:41 +02:00
Stuart Buchanan
d852308dc6 Nasal library load order
Previously, the Nasal files in fgdata/Nasal/*.nas were loaded in
file-name order.  This created a particular problem file files
beginning with "a" which might want to use props.nas.

This adds support for an ordered list of files to be defined
in the property tree that will be loaded before the rest of the
Nasal files.
2020-05-25 19:45:40 +01:00
James Turner
0423524b82 Fix crash on first-run on macOS 2020-05-25 14:13:21 +01:00
Lars Toenning
265d721bab [swift] Transfer connection settings to defaults.xml
Related to commit d0cb2f on fgdata
2020-05-24 14:15:27 +01:00
James Turner
54f660764e Tests: change how we find+load data files
Avoid encoding test-data as strings, since this exceeds MSVC limits
on string literals, and tests don’t need to be relocatable anyway,
so we can just hard-code the source location into config.h
2020-05-24 14:14:35 +01:00
James Turner
f242d1a226 Fix case sensitivity of Compositor spec names
https://sourceforge.net/p/flightgear/codetickets/2249/
2020-05-24 08:53:25 +01:00
James Turner
ce6bd859b3 Add Nasal source location to unit-tests 2020-05-22 17:35:24 +01:00
James Turner
3576f5ab3e Split NasalPositioned in two
File was getting huge, break it in half.
2020-05-22 16:38:53 +01:00
James Turner
d66edf42f5 Expose new index-of-interest FP methods to Nasal
Add some test checks for the Nasal API as well
2020-05-22 15:52:54 +01:00
James Turner
1eef7300be PosInit: fix a crash with invalid park-pos.
Add test-cases for this,
2020-05-21 23:19:39 +01:00
Lars Toenning
f3edffd42b Exit on startup if defaults.xml is corrupted 2020-05-21 22:49:57 +01:00
James Turner
fffcd14362 Fix FlightPlan procedure transition handling
Overhaul how transitions are stored in FlightPlan XML, and how
they’re exposed to Nasal. Simplify the Nasal access by making
‘sid_trans’ and ‘star_trans’ writeable.

Extend the unit-tests a lot to cover this, both from C++ and also
from Nasal

As part of this, overhaul the ownership of FlightPlan delegate
factories, to make it safer (use ref-counting of the factories,
and allow the factory to customise delegate clean-up behaviour)
2020-05-21 22:32:28 +01:00
James Turner
5f5a9d2a5e Fix RNAVProcedureTests::testIndexOf
Make FlightPlan::findIndexOfWp use the correct ::matches() method,
and special case this for basic waypoints. This fixes the behaviour
when loaded routes / procedures store a navaid-waypoint as basic.
2020-05-19 22:24:07 +01:00
James Turner
2759977ab6 Fix Launcher compositor setting 2020-05-19 22:22:04 +01:00
James Turner
8af20fbcab Fix for loading of FGFP plans.
Where the plan does not contain departure / arrival WPs, fire the
corresponding delegate methods after load, to run the selection logic.

Also, add a ‘loaded’ delegate callback, to give delegates a chance to
perform validation and fix-up after all flight-plan loads.
2020-05-19 22:01:42 +01:00
James Turner
63fe5237c6 Improve interaction of —parkpos and repositioning
Re-work how position-init and ATC-manager work together to do
parking assignment and fallback (when the parking is unavailable).
Improve the logic for the reposition case, and teach ATC-manager about
reposition explicitly.

When the parking is unavailable, explicitly fall back to best-runway
selection in finalizePosition.

Add many additional position-init tests, to cover all of this.
2020-05-19 18:00:34 +01:00
Bertrand Coconnier
1c10ccdd61 [JSBSim] Added a new property "accelerations/Nx".
Completed the set of properties accelerations/N{x,y,z}.
2020-05-18 23:00:36 +02:00
James Turner
1cf8e5641c Fix testing version of previous commit. 2020-05-18 11:47:11 +01:00
James Turner
645548cbcc Launcher: ensure cache rebuild dialog stays open.
Disable the auto-close behaviour, which was causing us to end the
rebuild too early, and then corrupt the DB
2020-05-18 11:46:17 +01:00
Lars Toenning
91263fc873 [swift] Initialize/cleanup traffic module correctly 2020-05-14 11:13:26 +01:00
Lars Toenning
7b9940f1b1 [swift] Code cleanup 2020-05-14 11:13:26 +01:00