diff --git a/map/bookmark.cpp b/map/bookmark.cpp index dd5ba52b17..6b269a8b91 100644 --- a/map/bookmark.cpp +++ b/map/bookmark.cpp @@ -335,7 +335,7 @@ void BookmarkCategory::SaveToKML(ostream & s) << " \n"; double const scale = bm->GetScale(); - if (scale != -1) + if (scale != -1.0) { /// @todo Factor out to separate function to use for other custom params. s << " \n" @@ -379,10 +379,7 @@ string BookmarkCategory::GenerateUniqueFileName(const string & path, string cons bool BookmarkCategory::SaveToKMLFile() { if (m_file.empty()) - { - /// @todo It's better to pass category name as file name here, isn't it? - m_file = GenerateUniqueFileName(GetPlatform().WritableDir(), m_file); - } + m_file = GenerateUniqueFileName(GetPlatform().WritableDir(), m_name); try { diff --git a/map/bookmark.hpp b/map/bookmark.hpp index ed52a83cdb..fef26b9c26 100644 --- a/map/bookmark.hpp +++ b/map/bookmark.hpp @@ -20,7 +20,7 @@ class Bookmark public: Bookmark() {} Bookmark(m2::PointD const & org, string const & name, string const & type) - : m_org(org), m_name(name), m_type(type) + : m_org(org), m_name(name), m_type(type), m_scale(-1.0) { } @@ -48,7 +48,7 @@ public: void ClearBookmarks(); - /// @name This function are called from Framework only. + /// @name Theese functions are called from Framework only. //@{ void AddBookmark(Bookmark const & bm, double scale); void ReplaceBookmark(size_t index, Bookmark const & bm, double scale); @@ -70,7 +70,7 @@ public: void DeleteBookmark(size_t index); - /// @name This fuctions are public for unit tests only. + /// @name Theese fuctions are public for unit tests only. /// You don't need to call them from client code. //@{ void LoadFromKML(ReaderPtr const & reader);