forked from organicmaps/organicmaps
[editor] HaveSomethingToUpload for specific mwm file.
This commit is contained in:
parent
0346f7de03
commit
07796c573a
2 changed files with 15 additions and 0 deletions
|
@ -510,6 +510,20 @@ bool Editor::HaveSomethingToUpload() const
|
|||
return false;
|
||||
}
|
||||
|
||||
bool Editor::HaveSomethingToUpload(MwmSet::MwmId const & mwmId) const
|
||||
{
|
||||
auto const found = m_features.find(mwmId);
|
||||
if (found != m_features.end())
|
||||
{
|
||||
for (auto const & index : found->second)
|
||||
{
|
||||
if (NeedsUpload(index.second.m_uploadStatus))
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
void Editor::UploadChanges(string const & key, string const & secret, TChangesetTags tags,
|
||||
TFinishUploadCallback callBack)
|
||||
{
|
||||
|
|
|
@ -102,6 +102,7 @@ public:
|
|||
EditableProperties GetEditableProperties(FeatureType const & feature) const;
|
||||
|
||||
bool HaveSomethingToUpload() const;
|
||||
bool HaveSomethingToUpload(MwmSet::MwmId const & mwmId) const;
|
||||
using TChangesetTags = map<string, string>;
|
||||
/// Tries to upload all local changes to OSM server in a separate thread.
|
||||
/// @param[in] tags should provide additional information about client to use in changeset.
|
||||
|
|
Loading…
Add table
Reference in a new issue