Fix some dumb paths in the code
Replace hard-coded path to my desktop with calls to SGPath::desktop() helper
This commit is contained in:
parent
016e1c89bc
commit
f463a0405e
3 changed files with 3 additions and 8 deletions
|
@ -591,11 +591,6 @@ void AirportDiagram::mouseReleaseEvent(QMouseEvent* me)
|
|||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#if 0
|
||||
img.save("/Users/jmt/Desktop/img.png");
|
||||
#endif
|
||||
}
|
||||
|
||||
QPainterPath AirportDiagram::pathForRunway(const RunwayData& r, const QTransform& t,
|
||||
|
|
|
@ -712,7 +712,7 @@ RouteBase::~RouteBase()
|
|||
|
||||
void RouteBase::dumpRouteToKML(const WayptVec& aRoute, const std::string& aName)
|
||||
{
|
||||
SGPath p = "/Users/jmt/Desktop/" + aName + ".kml";
|
||||
SGPath p = SGPath::desktop() / (aName + ".kml");
|
||||
sg_ofstream f(p);
|
||||
if (!f.is_open()) {
|
||||
SG_LOG(SG_NAVAID, SG_WARN, "unable to open:" << p);
|
||||
|
|
|
@ -281,7 +281,7 @@ void GPSTests::testGPS()
|
|||
WayptRef awy6 = new NavaidWaypoint(
|
||||
(FGPositioned*) fgFindAirportID("KJFK"), NULL);
|
||||
|
||||
SGPath p("/Users/jmt/Desktop/airways.kml");
|
||||
SGPath p SGPath::desktop() / "airways.kml";
|
||||
sg_ofstream f;
|
||||
f.open(p, fstream::out | fstream::trunc);
|
||||
|
||||
|
@ -312,7 +312,7 @@ void GPSTests::testGPS()
|
|||
f.close();
|
||||
|
||||
// procedures
|
||||
SGPath op("/Users/jmt/Desktop/procedures.kml");
|
||||
SGPath op SGPath::desktop() / "procedures.kml";
|
||||
f.open(op, fstream::out | fstream::trunc);
|
||||
|
||||
FGAirport* eham = (FGAirport*) fgFindAirportID("EHAM");
|
||||
|
|
Loading…
Reference in a new issue