diff options
author | Sebastian Holtermann <sebholt@xwmw.org> | 2016-11-30 21:08:41 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2016-12-07 13:23:58 (GMT) |
commit | 8c6f990fb600d042ebb7a21996280ef31798bc79 (patch) | |
tree | cb555414d94e75b89815973e56bb2db830a54ff6 /Source | |
parent | 49f8687e1601bacd3386d8393dc831124691715e (diff) | |
download | CMake-8c6f990fb600d042ebb7a21996280ef31798bc79.zip CMake-8c6f990fb600d042ebb7a21996280ef31798bc79.tar.gz CMake-8c6f990fb600d042ebb7a21996280ef31798bc79.tar.bz2 |
QtAutogen: New common bold logging method
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmQtAutoGenerators.cxx | 31 | ||||
-rw-r--r-- | Source/cmQtAutoGenerators.h | 1 |
2 files changed, 16 insertions, 16 deletions
diff --git a/Source/cmQtAutoGenerators.cxx b/Source/cmQtAutoGenerators.cxx index 23424c4..b497fb0 100644 --- a/Source/cmQtAutoGenerators.cxx +++ b/Source/cmQtAutoGenerators.cxx @@ -1077,11 +1077,9 @@ bool cmQtAutoGenerators::GenerateMocFiles( // actually write _automoc.cpp { - std::string msg = "Generating moc compilation "; + std::string msg = "Generating MOC compilation "; msg += this->OutMocCppFilenameRel; - cmSystemTools::MakefileColorEcho(cmsysTerminal_Color_ForegroundBlue | - cmsysTerminal_Color_ForegroundBold, - msg.c_str(), true, this->ColorOutput); + this->LogBold(msg); } // Make sure the parent directory exists bool success = this->makeParentDirectory(this->OutMocCppFilenameAbs); @@ -1119,11 +1117,9 @@ bool cmQtAutoGenerators::GenerateMoc(const std::string& sourceFile, &sourceNewerThanMoc); if (this->GenerateAll || !success || sourceNewerThanMoc >= 0) { { - std::string msg = "Generating moc source "; + std::string msg = "Generating MOC source "; msg += mocFileName; - cmSystemTools::MakefileColorEcho(cmsysTerminal_Color_ForegroundBlue | - cmsysTerminal_Color_ForegroundBold, - msg.c_str(), true, this->ColorOutput); + this->LogBold(msg); } // Make sure the parent directory exists @@ -1245,11 +1241,9 @@ bool cmQtAutoGenerators::GenerateUi(const std::string& realName, &sourceNewerThanUi); if (this->GenerateAll || !success || sourceNewerThanUi >= 0) { { - std::string msg = "Generating ui header "; + std::string msg = "Generating UIC header "; msg += uiOutputFile; - cmSystemTools::MakefileColorEcho(cmsysTerminal_Color_ForegroundBlue | - cmsysTerminal_Color_ForegroundBold, - msg.c_str(), true, this->ColorOutput); + this->LogBold(msg); } // Make sure the parent directory exists @@ -1395,11 +1389,9 @@ bool cmQtAutoGenerators::GenerateQrc(const std::string& qrcInputFile, if (this->GenerateAll || generateQrc) { { - std::string msg = "Generating qrc source "; + std::string msg = "Generating QRC source "; msg += qrcOutputFile; - cmSystemTools::MakefileColorEcho(cmsysTerminal_Color_ForegroundBlue | - cmsysTerminal_Color_ForegroundBold, - msg.c_str(), true, this->ColorOutput); + this->LogBold(msg); } // Make sure the parent directory exists @@ -1493,6 +1485,13 @@ void cmQtAutoGenerators::LogErrorNameCollision( this->LogError(err.str()); } +void cmQtAutoGenerators::LogBold(const std::string& message) +{ + cmSystemTools::MakefileColorEcho(cmsysTerminal_Color_ForegroundBlue | + cmsysTerminal_Color_ForegroundBold, + message.c_str(), true, this->ColorOutput); +} + void cmQtAutoGenerators::LogInfo(const std::string& message) { std::cout << message.c_str(); diff --git a/Source/cmQtAutoGenerators.h b/Source/cmQtAutoGenerators.h index 7cba1ea..466acb2 100644 --- a/Source/cmQtAutoGenerators.h +++ b/Source/cmQtAutoGenerators.h @@ -80,6 +80,7 @@ private: void LogErrorNameCollision( const std::string& message, const std::multimap<std::string, std::string>& collisions); + void LogBold(const std::string& message); void LogInfo(const std::string& message); void LogWarning(const std::string& message); void LogError(const std::string& message); |