From 9bc20fb18aeb68b43bebbf99a54a3637c178ee19 Mon Sep 17 00:00:00 2001 From: Leon Styhre Date: Sun, 6 Oct 2024 22:36:22 +0200 Subject: [PATCH] Some code format changes made by clang-format 18 --- es-app/src/GamelistFileParser.cpp | 8 ++++---- es-app/src/MiximageGenerator.cpp | 3 +-- es-app/src/PDFViewer.cpp | 5 ++--- es-app/src/main.cpp | 6 ++---- es-app/src/scrapers/Scraper.cpp | 3 +-- es-app/src/views/ViewController.cpp | 19 ++++++++----------- 6 files changed, 18 insertions(+), 26 deletions(-) diff --git a/es-app/src/GamelistFileParser.cpp b/es-app/src/GamelistFileParser.cpp index 47103d7f6..523230286 100644 --- a/es-app/src/GamelistFileParser.cpp +++ b/es-app/src/GamelistFileParser.cpp @@ -299,10 +299,10 @@ namespace GamelistFileParser // application restart. if (!Settings::getInstance()->getBool("ShowHiddenGames")) { if (file->getHidden()) { - LOG(LogDebug) << "GamelistFileParser::parseGamelist(): Skipping hidden " - << (type == GAME ? "file" : "folder") << " entry \"" - << file->getName() << "\"" - << " (\"" << file->getPath() << "\")"; + LOG(LogDebug) + << "GamelistFileParser::parseGamelist(): Skipping hidden " + << (type == GAME ? "file" : "folder") << " entry \"" << file->getName() + << "\"" << " (\"" << file->getPath() << "\")"; FileData* parent {file->getParent()}; delete file; // In case there are no entries left in the folder. diff --git a/es-app/src/MiximageGenerator.cpp b/es-app/src/MiximageGenerator.cpp index bf56b2bc8..c2b6d4b04 100644 --- a/es-app/src/MiximageGenerator.cpp +++ b/es-app/src/MiximageGenerator.cpp @@ -898,8 +898,7 @@ std::string MiximageGenerator::getSavePath() const #if defined(__ANDROID__) if (!Utils::FileSystem::exists(path + ".nomedia")) { - LOG(LogInfo) << "Creating \"no media\" file \"" << path + ".nomedia" - << "\"..."; + LOG(LogInfo) << "Creating \"no media\" file \"" << path + ".nomedia" << "\"..."; Utils::FileSystem::createEmptyFile(path + ".nomedia"); if (!Utils::FileSystem::exists(path + ".nomedia")) { LOG(LogWarning) << "Couldn't create file, permission problems?"; diff --git a/es-app/src/PDFViewer.cpp b/es-app/src/PDFViewer.cpp index 50092d62e..9d52d77e7 100644 --- a/es-app/src/PDFViewer.cpp +++ b/es-app/src/PDFViewer.cpp @@ -156,9 +156,8 @@ bool PDFViewer::startPDFViewer(FileData* game) #if (DEBUG_PDF_CONVERSION) LOG(LogDebug) << "Page " << i << ": Orientation: " << mPages[i].orientation << " / " - << "crop box width: " << width << " / " - << "crop box height: " << height << " / " - << "size ratio: " << width / height << " / " + << "crop box width: " << width << " / " << "crop box height: " << height + << " / " << "size ratio: " << width / height << " / " << "texture size: " << mPages[i].width << "x" << mPages[i].height; #endif } diff --git a/es-app/src/main.cpp b/es-app/src/main.cpp index 9e2e986ff..4b2e59fcb 100644 --- a/es-app/src/main.cpp +++ b/es-app/src/main.cpp @@ -873,8 +873,7 @@ int main(int argc, char* argv[]) } } if (!Utils::FileSystem::exists(themeDir + "/.nomedia")) { - LOG(LogInfo) << "Creating \"no media\" file \"" << themeDir + "/.nomedia" - << "\"..."; + LOG(LogInfo) << "Creating \"no media\" file \"" << themeDir + "/.nomedia" << "\"..."; Utils::FileSystem::createEmptyFile(themeDir + "/.nomedia"); if (!Utils::FileSystem::exists(themeDir + "/.nomedia")) { LOG(LogWarning) << "Couldn't create file, permission problems?"; @@ -1174,8 +1173,7 @@ int main(int argc, char* argv[]) #if defined(__ANDROID__) if (!Utils::FileSystem::exists(FileData::getROMDirectory() + ".nomedia")) { LOG(LogInfo) << "Creating \"no media\" file \"" - << FileData::getROMDirectory() + ".nomedia" - << "\"..."; + << FileData::getROMDirectory() + ".nomedia" << "\"..."; Utils::FileSystem::createEmptyFile(FileData::getROMDirectory() + ".nomedia"); if (!Utils::FileSystem::exists(FileData::getROMDirectory() + ".nomedia")) { LOG(LogWarning) << "Couldn't create file, permission problems?"; diff --git a/es-app/src/scrapers/Scraper.cpp b/es-app/src/scrapers/Scraper.cpp index a3316f0ab..93207fa2e 100644 --- a/es-app/src/scrapers/Scraper.cpp +++ b/es-app/src/scrapers/Scraper.cpp @@ -726,8 +726,7 @@ std::string getSaveAsPath(const ScraperSearchParams& params, #if defined(__ANDROID__) if (!Utils::FileSystem::exists(path + ".nomedia")) { - LOG(LogInfo) << "Creating \"no media\" file \"" << path + ".nomedia" - << "\"..."; + LOG(LogInfo) << "Creating \"no media\" file \"" << path + ".nomedia" << "\"..."; Utils::FileSystem::createEmptyFile(path + ".nomedia"); if (!Utils::FileSystem::exists(path + ".nomedia")) { LOG(LogWarning) << "Couldn't create file, permission problems?"; diff --git a/es-app/src/views/ViewController.cpp b/es-app/src/views/ViewController.cpp index a91c49b31..d08507a6b 100644 --- a/es-app/src/views/ViewController.cpp +++ b/es-app/src/views/ViewController.cpp @@ -177,21 +177,18 @@ void ViewController::setMenuColors() void ViewController::legacyAppDataDialog() { - const std::string upgradeMessage - { + const std::string upgradeMessage { "AS OF ES-DE 3.0 THE APPLICATION DATA DIRECTORY HAS CHANGED FROM \".emulationstation\" " "to \"ES-DE\"\nPLEASE RENAME YOUR CURRENT DATA DIRECTORY:\n" + #if defined(_WIN64) - Utils::String::replace(Utils::FileSystem::getAppDataDirectory(), "/", "\\") + - "\nTO THE FOLLOWING:\n" + - Utils::String::replace( - Utils::FileSystem::getParent(Utils::FileSystem::getAppDataDirectory()), "/", "\\") + - "\\ES-DE" - }; + Utils::String::replace(Utils::FileSystem::getAppDataDirectory(), "/", "\\") + + "\nTO THE FOLLOWING:\n" + + Utils::String::replace( + Utils::FileSystem::getParent(Utils::FileSystem::getAppDataDirectory()), "/", "\\") + + "\\ES-DE"}; #else - Utils::FileSystem::getAppDataDirectory() + "\nTO THE FOLLOWING:\n" + - Utils::FileSystem::getParent(Utils::FileSystem::getAppDataDirectory()) + "/ES-DE" - }; + Utils::FileSystem::getAppDataDirectory() + "\nTO THE FOLLOWING:\n" + + Utils::FileSystem::getParent(Utils::FileSystem::getAppDataDirectory()) + "/ES-DE"}; #endif mWindow->pushGui(new GuiMsgBox(