1
0
Fork 0
Commit graph

13337 commits

Author SHA1 Message Date
James Turner
7824571ec2 One more tweak for QtQuick header detection. 2017-10-04 12:07:12 +01:00
James Turner
e6402f505a Help debugging missing QtQuick headers. 2017-10-04 11:12:36 +01:00
James Turner
343fce4470 Improve mouse-warping with GraphicsWindowQt5 2017-10-03 08:21:15 +01:00
James Turner
0331180e4f Fix for UCrt runtime packaging, from Erik 2017-10-02 12:30:56 +01:00
James Turner
b7a2e993b6 Fix crash in traffic code
Hit an exception where no runway node was found creating the landing taxi.
Probably should not happen but anyway let's not crash
2017-09-29 12:49:22 +01:00
James Turner
a4f1f8aca1 Fix error in setSpeed / setAltitude from Nasal
https://sourceforge.net/p/flightgear/codetickets/1992/
2017-09-29 12:39:30 +01:00
James Turner
386c13a84d Fix Windows compilation 2017-09-29 09:51:20 +01:00
James Turner
78d735a97b Fix Linux compilation 2017-09-28 15:49:42 +01:00
James Turner
948435a465 Fix Ubuntu lib64 handling / Cmake 3.7 2017-09-28 15:12:06 +01:00
James Turner
4c4cfb3b44 Clean up CocoaMenuBar code
- remove use of Boost
- remove work-around for macOS < 10.7
2017-09-28 14:02:53 +01:00
James Turner
a89d747348 Unused include 2017-09-26 16:52:48 +01:00
James Turner
3b1b43f864 Include default airport in the location history
Only a quick hack, need to show more context to make this really
useful as a feature.
2017-09-26 16:52:48 +01:00
James Turner
06d206828a De-boost-ify position-init code
Also remove some now redundant parking-availability code, which is now
covered inside the dynamics code.
2017-09-26 16:52:48 +01:00
James Turner
a8e1fd4fd0 Move the user aircraft proxy into the AIManger
This should ensure there is always a proxy for the user in the AI
world for parking and ATC purposes.
2017-09-26 16:52:48 +01:00
James Turner
561e39e94f Quiet a log message. 2017-09-26 16:52:48 +01:00
James Turner
bb6510ad68 De-Boost-ify the AIManger, modernise to C++11 2017-09-26 16:52:48 +01:00
James Turner
972af3f254 Parking selection avoids AIObjects
This ensures AITraffic aircraft avoid parking stands occupied by
other AI objects, such as the user or MP aircraft
2017-09-26 16:52:48 +01:00
James Turner
c47325183c Simplify Qt version checks by requiring 5.4 2017-09-26 16:52:48 +01:00
James Turner
3a8d3506d6 Replace launcher aircraft list with QtQuick version
Improves various flow / layout / usability issues, since delegates
in ListView can do full event interaction.
2017-09-26 16:52:48 +01:00
James Turner
a005273724 Quiet a warning loading some ground-nets 2017-09-22 09:33:03 +01:00
James Turner
6db901a67f Add missing tr/qsTr wrappers to the launcher
Ensure all user-facing strings are annotated with translation macros,
so they can be translated soon.
2017-09-22 09:32:47 +01:00
James Turner
69934e04a6 Probably fix for Bug 1972 - AI parking positions
https://sourceforge.net/p/flightgear/codetickets/1972/
2017-09-21 18:37:43 +01:00
James Turner
66eb3d2690 Use a unique_ptr to manage FGAIFlightPlan 2017-09-21 18:37:14 +01:00
James Turner
c4aa3434ab Fix WS 2.0 paths to live inside a Terrain/ prefix 2017-09-21 17:48:30 +01:00
Florent Rougon
5fbf5fceab Fix build error in src/Main/test_autosaveMigration.cxx
The previous commit (32cc9be007) removed the second parameter of
FGGlobals::loadUserSettings(). Adapt testMigration() accordingly.
2017-09-20 22:19:01 +02:00
James Turner
32cc9be007 Enable auto-save migration.
When performing the migration, let the user know it happened, and to
be alert for any issues that might occur.
2017-09-20 17:57:25 +01:00
James Turner
c99504f321 Fix crash in Nasal _setChildren
We had a bit of stack smashing happening, fortunately the macOS runtime
is pretty good at detecting such things.
2017-09-19 08:20:08 +01:00
James Turner
351f6063c9 Permit more screenshots. (More than 1000) 2017-09-19 06:55:22 +01:00
James Turner
8e58c54544 Make routeRestrictionFromArg more robust. 2017-09-19 06:42:39 +01:00
James Turner
fba649a0e6 Fix crashes calling leg.setSpeed|Altitude(nil)
Treat passing nil as clearing the speed / altitude restriction for
the leg. Also default the second arg to ‘at’, so calling these
methods with a single numerical arg is permitted.
2017-09-19 06:36:32 +01:00
Torsten Dreyer
a82d955554 set fallback location to LKPR 2017-09-18 19:55:10 +02:00
Torsten Dreyer
7e9549c1bc new version: 2017.4.0 2017-09-17 12:14:03 +02:00
Torsten Dreyer
3eba38a682 new version: 2017.3.1 2017-09-17 12:14:03 +02:00
James Turner
1b8d0fb277 Nasal FlightPlan insertWp[After] return the leg. 2017-09-11 23:43:59 +01:00
James Turner
b0de9d5a11 Make Nasal Flightplan.indexOfWP work on Legs 2017-09-11 23:30:53 +01:00
James Turner
2acf2aa5ba Saving flightplans from Nasal.
Usage:

var fp0 = flightplan();
fp0.save("p6.xml");
2017-09-11 23:24:25 +01:00
James Turner
ddea3929f8 Fix clearing FlightPlan elements from Nasal.
Clearing the departure or destination elements, including the SID,
STAR or approach to nil, now works, e.g:

var fp = flightplan();
fp.departure = nil;
2017-09-11 23:24:24 +01:00
James Turner
194d17ec94 Add createFlightplan Nasal hook
Allows creating a new, inactive by empty Flightplan from Nasal. Can
also be used to load a flightplan:

var fp1 = createFlightplan();
var fp2 = createFlightplan("p3.xml");
2017-09-11 23:24:24 +01:00
James Turner
ca067b1a82 Fix Nasal owning of FlightPlans
Also refactor delegate ownership to be flat instead of nested, much
easier as the number of delegates has grown.
2017-09-11 23:24:24 +01:00
James Turner
d422992b2d Re-indent my fix from yesterday to 2-space mode.
This will fix a misleading indentation warning from GCC, although to
doubly sure I also added explicit braces to the code.
2017-09-09 19:03:53 +01:00
James Turner
bf2c363e50 Fix carrier starts
Rewrite the position-init code for carrier starts, to precisely wait
on the carrier model being loaded, before proceeding with FDM init.
This allows the FDM to see the correct carrier model in the ground
cache, and hence avoids starting in the water.

To implement this, the CheckSceneryVisitor is used to force the carrier
model to be loaded while the splash-screen is visible.
2017-09-08 22:31:22 +01:00
James Turner
91d3229514 Catch large ground-cache requests.
In some testing, JSBsim sometimes passed extremely large values into
this function (larger than the radius of the earth). This causes
every tile on the planet to be scheduled if using the standard STG
terrain, effectively blocking startup.

This code allows us a chance to catch this case via logging, but does
not fix the underlying issues.
2017-09-04 22:48:38 +01:00
James Turner
657f811548 Activating a FlightPlan sets it on the route-mgr
This enables the Route-manager FP to be replaced from Nasal, as well as
via the load-route command.
2017-09-04 22:48:38 +01:00
Torsten Dreyer
a27ea4dfe6 remove orphan directories with --remove-orphan 2017-09-01 10:33:35 +02:00
Richard Harrison
5f3e4bdde7 Fix for the pilot list (and possibly other things) that fail with the new _setValues API.
The problem is that the two aren't functionally equivalent; the Nasal version would fail silently - whereas the new C++ version gave a runtime error.

The immediate fix is therefore to simply remove the runtime error.
2017-08-30 22:19:01 +02:00
James Turner
b6bfe45759 Change how anti-aliasing is requested by the launcher.
This seems to fix https://sourceforge.net/p/flightgear/codetickets/1971/ 
for me, but I have some reservations about my testing of this, so
pushing this change to get wider feedback.
2017-08-29 14:22:32 +01:00
Florent Rougon
30aebc783b FGLogger::Log: use std::unique_ptr to manage the sg_ofstream instance
No more raw pointer; RAII is good.
2017-08-27 16:13:01 +02:00
Florent Rougon
b56f694ffd FGLogger: fix error handling when file opening fails; modernize and simplify
The bug fix is:

-    if (!log.output) {
+    if ( !(*log.output) ) {

(i.e., testing the sg_ofstream instance instead of its address) and then
ensuring that the corresponding Log instance is removed from _logs and
destroyed.

The "destroy" part is made automatic by using std::unique_ptr instead of
raw pointers. This allows to simplify several areas of the code.

Don't provide custom definitions for the constructor and destructor of
FGLogger anymore, now that they don't need to do anything: IIRC, this
allows compilers to do some optimizations according to the C++ standard.
2017-08-27 16:13:01 +02:00
Florent Rougon
2a5e3d06b2 Security: don't allow FGLogger to overwrite arbitrary files
Since the paths of files overwritten by FGLogger come from the property
tree[1], they must be validated before we decide to write to these
files.

[1] Except for the "empty" case, which uses the default name
    'fg_log.csv'. This file is deemed acceptable to overwrite in the
    current directory, as the name is completely fixed and clearly
    FG-specific.
2017-08-27 16:09:18 +02:00
Florent Rougon
c7a2aef599 Call fgInitAllowedPaths() earlier: after Options::processOptions()
Call fgInitAllowedPaths() right after Options::processOptions() (which,
among other things, determines $FG_ROOT and processes
--allow-nasal-read). This way, fgInitAllowedPaths() can be used in much
more code, such as when initializing subsystems.
2017-08-27 16:07:51 +02:00