StelObserver.cpp   StelObserver.cpp 
skipping to change at line 30 skipping to change at line 30
#include "StelObserver.hpp" #include "StelObserver.hpp"
#include "StelUtils.hpp" #include "StelUtils.hpp"
#include "SolarSystem.hpp" #include "SolarSystem.hpp"
#include "Planet.hpp" #include "Planet.hpp"
#include "StelTranslator.hpp" #include "StelTranslator.hpp"
#include "StelApp.hpp" #include "StelApp.hpp"
#include "StelCore.hpp" #include "StelCore.hpp"
#include "StelLocationMgr.hpp" #include "StelLocationMgr.hpp"
#include "StelModuleMgr.hpp" #include "StelModuleMgr.hpp"
#include "LandscapeMgr.hpp"
#include <QDebug> #include <QDebug>
#include <QSettings> #include <QSettings>
#include <QStringList> #include <QStringList>
class ArtificialPlanet : public Planet class ArtificialPlanet : public Planet
{ {
public: public:
ArtificialPlanet(const PlanetP& orig); ArtificialPlanet(const PlanetP& orig);
void setDest(const PlanetP& dest); void setDest(const PlanetP& dest);
skipping to change at line 261 skipping to change at line 262
void SpaceShipObserver::update(double deltaTime) void SpaceShipObserver::update(double deltaTime)
{ {
timeToGo -= deltaTime; timeToGo -= deltaTime;
// If move is over // If move is over
if (timeToGo <= 0.) if (timeToGo <= 0.)
{ {
timeToGo = 0.; timeToGo = 0.;
currentLocation = moveTargetLocation; currentLocation = moveTargetLocation;
LandscapeMgr* ls = GETSTELMODULE(LandscapeMgr);
if (ls->getFlagLandscapeAutoSelection())
{
// If we have a landscape for target planet then set
it, otherwise use default landscape
if (ls->getAllLandscapeNames().indexOf(currentLocati
on.planetName)>0)
ls->setCurrentLandscapeName(currentLocation.
planetName);
else
ls->setCurrentLandscapeID(ls->getDefaultLand
scapeID());
}
} }
else else
{ {
if (artificialPlanet) if (artificialPlanet)
{ {
// Update SpaceShip position // Update SpaceShip position
static_cast<ArtificialPlanet*>(artificialPlanet.data ())->computeAverage(timeToGo/(timeToGo + deltaTime)); static_cast<ArtificialPlanet*>(artificialPlanet.data ())->computeAverage(timeToGo/(timeToGo + deltaTime));
// TRANSLATORS: "Planet name" displayed when "flying " to another planet with Ctrl+G. // TRANSLATORS: "Planet name" displayed when "flying " to another planet with Ctrl+G.
currentLocation.planetName = N_("SpaceShip"); currentLocation.planetName = N_("SpaceShip");
currentLocation.name = q_(moveStartLocation.planetNa me) + " -> " + q_(moveTargetLocation.planetName); currentLocation.name = q_(moveStartLocation.planetNa me) + " -> " + q_(moveTargetLocation.planetName);
 End of changes. 2 change blocks. 
0 lines changed or deleted 14 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/