mirror of
https://github.com/reactos/CMake.git
synced 2024-12-13 22:58:41 +00:00
AUTOGEN: Generators: Moc/UicSkipTest methods
This commit is contained in:
parent
94c319f933
commit
d58b6bf31c
@ -610,16 +610,7 @@ void cmQtAutoGenerators::ParseContentForUic(
|
||||
const std::string& absFilename, const std::string& contentsString,
|
||||
std::map<std::string, std::vector<std::string> >& includedUis)
|
||||
{
|
||||
if (this->UicExecutable.empty()) {
|
||||
return;
|
||||
}
|
||||
// Check skip list
|
||||
if (ListContains(this->SkipUic, absFilename)) {
|
||||
if (this->Verbose) {
|
||||
std::ostringstream err;
|
||||
err << "AUTOUIC: Skipping " << absFilename << "\n";
|
||||
this->LogInfo(err.str());
|
||||
}
|
||||
if (this->UicExecutable.empty() || this->UicSkipTest(absFilename)) {
|
||||
return;
|
||||
}
|
||||
|
||||
@ -653,16 +644,7 @@ bool cmQtAutoGenerators::ParseContentForMoc(
|
||||
const std::vector<std::string>& headerExtensions,
|
||||
std::map<std::string, std::string>& includedMocs, bool relaxed)
|
||||
{
|
||||
if (this->MocExecutable.empty()) {
|
||||
return true;
|
||||
}
|
||||
// Check skip list
|
||||
if (ListContains(this->SkipMoc, absFilename)) {
|
||||
if (this->Verbose) {
|
||||
std::ostringstream err;
|
||||
err << "AUTOMOC: Skipping " << absFilename << "\n";
|
||||
this->LogInfo(err.str());
|
||||
}
|
||||
if (this->MocExecutable.empty() || this->MocSkipTest(absFilename)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -921,14 +903,7 @@ void cmQtAutoGenerators::ParseHeaders(
|
||||
if (!this->MocExecutable.empty() &&
|
||||
(absHeadersMoc.find(headerName) != absHeadersMoc.end()) &&
|
||||
(includedMocs.find(headerName) == includedMocs.end())) {
|
||||
if (ListContains(this->SkipMoc, headerName)) {
|
||||
// Skip
|
||||
if (this->Verbose) {
|
||||
std::ostringstream err;
|
||||
err << "AUTOMOC: Skipping " << headerName << "\n";
|
||||
this->LogInfo(err.str());
|
||||
}
|
||||
} else {
|
||||
if (!this->MocSkipTest(headerName)) {
|
||||
// Process
|
||||
if (this->Verbose) {
|
||||
std::ostringstream err;
|
||||
@ -1396,6 +1371,38 @@ bool cmQtAutoGenerators::GenerateQrc(const std::string& qrcInputFile,
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Tests if the file name is in the skip list
|
||||
*/
|
||||
bool cmQtAutoGenerators::MocSkipTest(const std::string& absFilename)
|
||||
{
|
||||
if (ListContains(this->SkipMoc, absFilename)) {
|
||||
if (this->Verbose) {
|
||||
std::ostringstream msg;
|
||||
msg << "AUTOMOC: Skipping " << absFilename << "\n";
|
||||
this->LogInfo(msg.str());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Tests if the file name is in the skip list
|
||||
*/
|
||||
bool cmQtAutoGenerators::UicSkipTest(const std::string& absFilename)
|
||||
{
|
||||
if (ListContains(this->SkipUic, absFilename)) {
|
||||
if (this->Verbose) {
|
||||
std::ostringstream msg;
|
||||
msg << "AUTOUIC: Skipping " << absFilename << "\n";
|
||||
this->LogInfo(msg.str());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Collects name collisions as output/input pairs
|
||||
* @return True if there were collisions
|
||||
|
@ -86,6 +86,9 @@ private:
|
||||
|
||||
void Init();
|
||||
|
||||
bool MocSkipTest(const std::string& absFilename);
|
||||
bool UicSkipTest(const std::string& absFilename);
|
||||
|
||||
bool NameCollisionTest(const std::map<std::string, std::string>& genFiles,
|
||||
std::multimap<std::string, std::string>& collisions);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user