refs #576, improved filters

* initially clear filters
* fixed handling of simulator flags
* rename field
* changed order of * handling
This commit is contained in:
Klaus Basan
2016-01-27 18:23:16 +01:00
parent 68d2a4bc81
commit 8f216f510f
8 changed files with 25 additions and 9 deletions

View File

@@ -95,7 +95,7 @@ namespace BlackGui
this->m_airlineIcao.isEmpty() && this->m_airlineName.isEmpty() &&
this->m_liveryCode.isEmpty() &&
!this->m_distributor.hasValidDbKey() &&
this->m_simulatorInfo.isNoSimulator()
(this->m_simulatorInfo.isNoSimulator() || this->m_simulatorInfo.isAllSimulators())
);
}

View File

@@ -38,17 +38,18 @@ namespace BlackGui
return v.contains(filterNoWildcard, cs);
}
// ends with
if (f.endsWith('*'))
{
return v.startsWith(filterNoWildcard, cs);
}
// starting with
if (f.startsWith('*'))
{
return v.endsWith(filterNoWildcard, cs);
}
if (f.endsWith('*'))
{
return v.startsWith(filterNoWildcard, cs);
}
// should never happen
Q_ASSERT(false);
return false;