StelLocationMgr.hpp   StelLocationMgr.hpp 
skipping to change at line 45 skipping to change at line 45
public: public:
//! Default constructor //! Default constructor
StelLocationMgr(); StelLocationMgr();
//! Destructor //! Destructor
~StelLocationMgr(); ~StelLocationMgr();
//! Return the model containing all the city //! Return the model containing all the city
QStringListModel* getModelAll() {return modelAllLocation;} QStringListModel* getModelAll() {return modelAllLocation;}
//! Return the list of all loaded locations
QList<StelLocation> getAll() const {return locations.values();}
//! Return the StelLocation for the given row (match modelAllLocatio n index row) //! Return the StelLocation for the given row (match modelAllLocatio n index row)
const StelLocation locationForSmallString(const QString& s) const; const StelLocation locationForSmallString(const QString& s) const;
//! Get whether a location can be permanently added to the list of u ser locations //! Get whether a location can be permanently added to the list of u ser locations
//! The main constraint is that the small string must be unique //! The main constraint is that the small string must be unique
bool canSaveUserLocation(const StelLocation& loc) const; bool canSaveUserLocation(const StelLocation& loc) const;
//! Add permanently a location to the list of user locations //! Add permanently a location to the list of user locations
//! It is later identified by its small string //! It is later identified by its small string
bool saveUserLocation(const StelLocation& loc); bool saveUserLocation(const StelLocation& loc);
skipping to change at line 67 skipping to change at line 70
//! If the location comes from the base read only list, it cannot be deleted //! If the location comes from the base read only list, it cannot be deleted
//! @param id the location ID //! @param id the location ID
bool canDeleteUserLocation(const QString& id) const; bool canDeleteUserLocation(const QString& id) const;
//! Delete permanently the given location from the list of user loca tions //! Delete permanently the given location from the list of user loca tions
//! If the location comes from the base read only list, it cannot be deleted and false is returned //! If the location comes from the base read only list, it cannot be deleted and false is returned
//! @param id the location ID //! @param id the location ID
bool deleteUserLocation(const QString& id); bool deleteUserLocation(const QString& id);
private: private:
void generateBinaryLocationFile(const QString& txtFile, bool isUserL
ocation, const QString& binFile) const;
//! Load cities from a file //! Load cities from a file
void loadCities(const QString& fileName, bool isUserLocation); QMap<QString, StelLocation> loadCities(const QString& fileName, bool
isUserLocation) const;
QMap<QString, StelLocation> loadCitiesBin(const QString& fileName) c
onst;
//! Model containing all the city information //! Model containing all the city information
QStringListModel* modelAllLocation; QStringListModel* modelAllLocation;
//! The list of all loaded locations //! The list of all loaded locations
QMap<QString, StelLocation> locations; QMap<QString, StelLocation> locations;
}; };
#endif // _STELLOCATIONMGR_HPP_ #endif // _STELLOCATIONMGR_HPP_
 End of changes. 3 change blocks. 
1 lines changed or deleted 10 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/