1
0
Fork 0

Minor cleanup in parse_port_config.

This commit is contained in:
ThorstenB 2017-11-15 19:21:01 +01:00
parent 94a8ba8f9b
commit 27e2776890

View file

@ -124,62 +124,44 @@ FGIO::parse_port_config( const string& config )
atcsim->set_path_names(tokens[2], tokens[3], tokens[4], tokens[5]); atcsim->set_path_names(tokens[2], tokens[3], tokens[4], tokens[5]);
return atcsim; return atcsim;
} else if ( protocol == "atlas" ) { } else if ( protocol == "atlas" ) {
FGAtlas *atlas = new FGAtlas; io = new FGAtlas;
io = atlas;
} else if ( protocol == "opengc" ) { } else if ( protocol == "opengc" ) {
FGOpenGC *opengc = new FGOpenGC; io = new FGOpenGC;
io = opengc;
} else if ( protocol == "AV400" ) { } else if ( protocol == "AV400" ) {
FGAV400 *av400 = new FGAV400; io = new FGAV400;
io = av400;
} else if ( protocol == "AV400Sim" ) { } else if ( protocol == "AV400Sim" ) {
FGAV400Sim *av400sim = new FGAV400Sim; io = new FGAV400Sim;
io = av400sim;
} else if ( protocol == "AV400WSimA" ) { } else if ( protocol == "AV400WSimA" ) {
FGAV400WSimA *av400wsima = new FGAV400WSimA; io = new FGAV400WSimA;
io = av400wsima;
} else if ( protocol == "AV400WSimB" ) { } else if ( protocol == "AV400WSimB" ) {
FGAV400WSimB *av400wsimb = new FGAV400WSimB; io = new FGAV400WSimB;
io = av400wsimb;
} else if ( protocol == "garmin" ) { } else if ( protocol == "garmin" ) {
FGGarmin *garmin = new FGGarmin; io = new FGGarmin();
io = garmin;
} else if ( protocol == "igc" ) { } else if ( protocol == "igc" ) {
IGCProtocol *igc = new IGCProtocol; io = new IGCProtocol;
io = igc;
} else if ( protocol == "joyclient" ) { } else if ( protocol == "joyclient" ) {
FGJoyClient *joyclient = new FGJoyClient; io = new FGJoyClient;
io = joyclient;
} else if ( protocol == "jsclient" ) { } else if ( protocol == "jsclient" ) {
FGJsClient *jsclient = new FGJsClient; io = new FGJsClient;
io = jsclient;
} else if ( protocol == "native" ) { } else if ( protocol == "native" ) {
FGNative *native = new FGNative; io = new FGNative;
io = native;
} else if ( protocol == "native-ctrls" ) { } else if ( protocol == "native-ctrls" ) {
FGNativeCtrls *native_ctrls = new FGNativeCtrls; io = new FGNativeCtrls;
io = native_ctrls;
} else if ( protocol == "native-fdm" ) { } else if ( protocol == "native-fdm" ) {
FGNativeFDM *native_fdm = new FGNativeFDM; io = new FGNativeFDM;
io = native_fdm;
} else if ( protocol == "native-gui" ) { } else if ( protocol == "native-gui" ) {
FGNativeGUI *net_gui = new FGNativeGUI; io = new FGNativeGUI;
io = net_gui;
} else if ( protocol == "nmea" ) { } else if ( protocol == "nmea" ) {
FGNMEA *nmea = new FGNMEA; io = new FGNMEA();
io = nmea;
} else if ( protocol == "props" || protocol == "telnet" ) { } else if ( protocol == "props" || protocol == "telnet" ) {
io = new FGProps( tokens ); io = new FGProps( tokens );
return io; return io;
} else if ( protocol == "pve" ) { } else if ( protocol == "pve" ) {
FGPVE *pve = new FGPVE; io = new FGPVE;
io = pve;
} else if ( protocol == "ray" ) { } else if ( protocol == "ray" ) {
FGRAY *ray = new FGRAY; io = new FGRAY;
io = ray;
} else if ( protocol == "rul" ) { } else if ( protocol == "rul" ) {
FGRUL *rul = new FGRUL; io = new FGRUL;
io = rul;
} else if ( protocol == "generic" ) { } else if ( protocol == "generic" ) {
FGGeneric *generic = new FGGeneric( tokens ); FGGeneric *generic = new FGGeneric( tokens );
if (!generic->getInitOk()) if (!generic->getInitOk())