File tree Expand file tree Collapse file tree 1 file changed +15
-1
lines changed
src/core/management_layer/content/projects Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Original file line number Diff line number Diff line change @@ -1111,7 +1111,21 @@ void ProjectsManager::addOrUpdateCloudProject(const Domain::ProjectInfo& _projec
11111111 } else {
11121112 const auto posterPath = d->projectPosterPath (projectPath);
11131113 QFile posterFile (posterPath);
1114- if (posterFile.open (QIODevice::WriteOnly | QIODevice::Truncate)) {
1114+ //
1115+ // Если постер не изменился
1116+ //
1117+ if (posterFile.exists () && posterFile.size () == _projectInfo.poster .size ()) {
1118+ //
1119+ // ... ничего не делаем
1120+ //
1121+ }
1122+ //
1123+ // А если изменился
1124+ //
1125+ else if (posterFile.open (QIODevice::WriteOnly | QIODevice::Truncate)) {
1126+ //
1127+ // ... то сохраним его в файл
1128+ //
11151129 posterFile.write (_projectInfo.poster );
11161130 posterFile.close ();
11171131 }
You can’t perform that action at this time.
0 commit comments