Remove use of C-style casts

This commit is contained in:
staticssleever668
2021-10-11 23:28:28 +03:00
committed by Jonas Kvinge
parent 637772f8f0
commit b38ad81928
41 changed files with 84 additions and 84 deletions

View File

@@ -440,7 +440,7 @@ void DiscogsCoverProvider::HandleReleaseReply(QNetworkReply *reply, const quint6
int width = obj_image["width"].toInt();
int height = obj_image["height"].toInt();
if (width < 300 || height < 300) continue;
const float aspect_score = float(1.0) - float(std::max(width, height) - std::min(width, height)) / float(std::max(height, width));
const float aspect_score = static_cast<float>(1.0) - static_cast<float>(std::max(width, height) - std::min(width, height)) / static_cast<float>(std::max(height, width));
if (aspect_score < 0.85) continue;
CoverProviderSearchResult result;
result.artist = artist;