diff --git a/src/Instrumentation/KLN89/kln89_page_apt.cxx b/src/Instrumentation/KLN89/kln89_page_apt.cxx index db4a8c115..83f0bc3b0 100644 --- a/src/Instrumentation/KLN89/kln89_page_apt.cxx +++ b/src/Instrumentation/KLN89/kln89_page_apt.cxx @@ -650,7 +650,6 @@ void KLN89AptPage::EntPressed() { GPSWaypoint* wp = new GPSWaypoint; *wp = *(_approachRoutes[_curIaf]->waypoints[0]); // Need to make copies here since we're going to alter ID and type sometimes string iafid = wp->id; - //wp->id += 'i'; _kln89->_approachFP->waypoints.push_back(wp); for(unsigned int i=0; i<_IAP.size(); ++i) { if(_IAP[i]->id != iafid) { // Don't duplicate waypoints that are part of the initial fix list and the approach procedure list. @@ -666,11 +665,6 @@ void KLN89AptPage::EntPressed() { _kln89->_approachFP->waypoints.push_back(wp); } } - // Only add 1 missed approach procedure waypoint for now. I think this might be standard always anyway. - wp = new GPSWaypoint; - *wp = *_MAP[0]; - //wp->id += 'h'; - _kln89->_approachFP->waypoints.push_back(wp); _iafDialog = false; _addDialog = true; _maxULinePos = _kln89->_approachFP->waypoints.size() + 1; @@ -719,11 +713,9 @@ void KLN89AptPage::EntPressed() { } else if(_uLinePos > 4) { _approachRoutes.clear(); _IAP.clear(); - _MAP.clear(); _curIaf = 0; _approachRoutes = ((FGNPIAP*)(_iaps[_uLinePos-5]))->_approachRoutes; _IAP = ((FGNPIAP*)(_iaps[_uLinePos-5]))->_IAP; - _MAP = ((FGNPIAP*)(_iaps[_uLinePos-5]))->_MAP; _curIap = _uLinePos - 5; // TODO - handle the start of list ! no. 1, and the end of list not sequential! _uLinePos = 1; if(_approachRoutes.size() > 1) { @@ -749,12 +741,6 @@ void KLN89AptPage::EntPressed() { _kln89->_approachFP->waypoints.push_back(wp); } } - // Only add 1 missed approach procedure waypoint for now. I think this might be standard always anyway. - wp = new GPSWaypoint; - *wp = *_MAP[0]; - //wp->id += 'h'; - _kln89->_approachFP->waypoints.push_back(wp); - _addDialog = true; _maxULinePos = 1; } diff --git a/src/Instrumentation/dclgps.cxx b/src/Instrumentation/dclgps.cxx index 4a2ccabf3..6feb0a286 100644 --- a/src/Instrumentation/dclgps.cxx +++ b/src/Instrumentation/dclgps.cxx @@ -254,7 +254,6 @@ void DCLGPS::init() { iap->_rwyStr = "12"; iap->_approachRoutes.clear(); iap->_IAP.clear(); - iap->_MAP.clear(); // ------- wp = new GPSWaypoint; wp->id = "GOBBS"; @@ -324,7 +323,7 @@ void DCLGPS::init() { if(cwp) { *wp = *cwp; wp->appType = GPS_MAHP; - iap->_MAP.push_back(wp); + iap->_IAP.push_back(wp); } else { //cout << "Unable to find waypoint " << wp->id << '\n'; } diff --git a/src/Instrumentation/dclgps.hxx b/src/Instrumentation/dclgps.hxx index 9594304e6..76dd764dd 100644 --- a/src/Instrumentation/dclgps.hxx +++ b/src/Instrumentation/dclgps.hxx @@ -143,8 +143,7 @@ public: vector<GPSFlightPlan*> _approachRoutes; // The approach route(s) from the IAF(s) to the IF. // NOTE: It is an assumption in the code that uses this that there is a unique IAF per approach route. vector<GPSWaypoint*> _IAP; // The compulsory waypoints of the approach procedure (may duplicate one of the above). - // _IAP includes the FAF and MAF. - vector<GPSWaypoint*> _MAP; // The missed approach procedure (doesn't include the MAF). + // _IAP includes the FAF and MAF, and the missed approach waypoints. }; typedef vector < FGIAP* > iap_list_type;