mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-31 04:25:35 +08:00
Ref T776, renamed some matching settings
* the forced values did not force anything * also adjusted UI form
This commit is contained in:
committed by
Mat Sutcliffe
parent
1da66ce6e9
commit
2607ebd7c6
@@ -1440,13 +1440,13 @@ namespace BlackCore
|
||||
|
||||
// military / civilian
|
||||
bool milFlagReduced = false;
|
||||
if (mode.testFlag(CAircraftMatcherSetup::ByForceMilitary) && remoteAircraft.isMilitary())
|
||||
if (mode.testFlag(CAircraftMatcherSetup::ByMilitary) && remoteAircraft.isMilitary())
|
||||
{
|
||||
matchedModels = ifPossibleReduceByMilitaryFlag(remoteAircraft, matchedModels, reduced, reduceLog);
|
||||
milFlagReduced = true;
|
||||
}
|
||||
|
||||
if (!milFlagReduced && mode.testFlag(CAircraftMatcherSetup::ByForceCivilian) && !remoteAircraft.isMilitary())
|
||||
if (!milFlagReduced && mode.testFlag(CAircraftMatcherSetup::ByCivilian) && !remoteAircraft.isMilitary())
|
||||
{
|
||||
matchedModels = ifPossibleReduceByMilitaryFlag(remoteAircraft, matchedModels, reduced, reduceLog);
|
||||
milFlagReduced = true;
|
||||
|
||||
@@ -51,8 +51,8 @@ namespace BlackGui
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ByLivery, readonly);
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ByCombinedCode, readonly);
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ByVtol, readonly);
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ByForceMilitary, readonly);
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ByForceCivilian, readonly);
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ByMilitary, readonly);
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ByCivilian, readonly);
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ScoreIgnoreZeros, readonly);
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ScorePreferColorLiveries, readonly);
|
||||
CGuiUtility::checkBoxReadOnly(ui->cb_ModelSetRemoveFailed, readonly);
|
||||
@@ -112,8 +112,8 @@ namespace BlackGui
|
||||
|
||||
ui->cb_ByLivery->setChecked(mode.testFlag(CAircraftMatcherSetup::ByLivery));
|
||||
ui->cb_ByFamily->setChecked(mode.testFlag(CAircraftMatcherSetup::ByFamily));
|
||||
ui->cb_ByForceMilitary->setChecked(mode.testFlag(CAircraftMatcherSetup::ByForceMilitary));
|
||||
ui->cb_ByForceCivilian->setChecked(mode.testFlag(CAircraftMatcherSetup::ByForceCivilian));
|
||||
ui->cb_ByMilitary->setChecked(mode.testFlag(CAircraftMatcherSetup::ByMilitary));
|
||||
ui->cb_ByCivilian->setChecked(mode.testFlag(CAircraftMatcherSetup::ByCivilian));
|
||||
ui->cb_CategoryGlider->setChecked(mode.testFlag(CAircraftMatcherSetup::ByCategoryGlider));
|
||||
ui->cb_CategoryMilitaryAircraft->setChecked(mode.testFlag(CAircraftMatcherSetup::ByCategoryMilitary));
|
||||
ui->cb_CategorySmallAircraft->setChecked(mode.testFlag(CAircraftMatcherSetup::ByCategorySmallAircraft));
|
||||
@@ -203,8 +203,8 @@ namespace BlackGui
|
||||
ui->rb_ByIcaoDataAircraft1st->isChecked(), ui->rb_ByIcaoDataAirline1st->isChecked(),
|
||||
ui->cb_ByFamily->isChecked(), ui->cb_ByLivery->isChecked(),
|
||||
ui->cb_ByCombinedCode->isChecked(),
|
||||
ui->cb_ByForceMilitary->isChecked(),
|
||||
ui->cb_ByForceCivilian->isChecked(),
|
||||
ui->cb_ByMilitary->isChecked(),
|
||||
ui->cb_ByCivilian->isChecked(),
|
||||
ui->cb_ByVtol->isChecked(),
|
||||
ui->cb_CategoryGlider->isChecked(),
|
||||
ui->cb_CategoryMilitaryAircraft->isChecked(),
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>315</width>
|
||||
<height>664</height>
|
||||
<width>378</width>
|
||||
<height>696</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
@@ -272,69 +272,14 @@
|
||||
<property name="bottomMargin">
|
||||
<number>3</number>
|
||||
</property>
|
||||
<item row="2" column="0" colspan="2">
|
||||
<widget class="Line" name="line_Reduction">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="QCheckBox" name="cb_ByLivery">
|
||||
<item row="1" column="0">
|
||||
<widget class="QRadioButton" name="rb_AirlineGroupNo">
|
||||
<property name="text">
|
||||
<string> livery</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="1">
|
||||
<widget class="QCheckBox" name="cb_ByForceCivilian">
|
||||
<property name="toolTip">
|
||||
<string>inbound civilian force matched civilian</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>force civilian</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="2">
|
||||
<widget class="QCheckBox" name="cb_ByFamily">
|
||||
<property name="text">
|
||||
<string>family</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QCheckBox" name="cb_ByCombinedCode">
|
||||
<property name="text">
|
||||
<string>combined code</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1" colspan="2">
|
||||
<widget class="QCheckBox" name="cb_ByVtol">
|
||||
<property name="toolTip">
|
||||
<string>Vertical Takeoff or Landing</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>VTOL (helicopters and such)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QCheckBox" name="cb_ByModelString">
|
||||
<property name="text">
|
||||
<string>model string</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<widget class="QCheckBox" name="cb_ByForceMilitary">
|
||||
<property name="toolTip">
|
||||
<string>inbound military force matched military</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>force military</string>
|
||||
<string>no airline group</string>
|
||||
</property>
|
||||
<attribute name="buttonGroup">
|
||||
<string notr="true">bg_AirlineGroup</string>
|
||||
</attribute>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
@@ -357,14 +302,59 @@
|
||||
</attribute>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QRadioButton" name="rb_AirlineGroupNo">
|
||||
<item row="3" column="2">
|
||||
<widget class="QCheckBox" name="cb_ByFamily">
|
||||
<property name="text">
|
||||
<string>no airline group</string>
|
||||
<string>family</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="QCheckBox" name="cb_ByLivery">
|
||||
<property name="text">
|
||||
<string> livery</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="1">
|
||||
<widget class="QCheckBox" name="cb_ByCivilian">
|
||||
<property name="toolTip">
|
||||
<string>inbound civilian try to match civilian</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>civilian</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0" colspan="3">
|
||||
<widget class="Line" name="line_Reduction">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1" colspan="2">
|
||||
<widget class="QCheckBox" name="cb_ByVtol">
|
||||
<property name="toolTip">
|
||||
<string>Vertical Takeoff or Landing</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>VTOL (helicopters and such)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QCheckBox" name="cb_ByModelString">
|
||||
<property name="text">
|
||||
<string>model string</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QCheckBox" name="cb_ByCombinedCode">
|
||||
<property name="text">
|
||||
<string>combined code</string>
|
||||
</property>
|
||||
<attribute name="buttonGroup">
|
||||
<string notr="true">bg_AirlineGroup</string>
|
||||
</attribute>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
@@ -377,6 +367,16 @@
|
||||
</attribute>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<widget class="QCheckBox" name="cb_ByMilitary">
|
||||
<property name="toolTip">
|
||||
<string>inbound military try to find military</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>military</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="2">
|
||||
<widget class="QRadioButton" name="rb_AirlineGroupAsAirline">
|
||||
<property name="text">
|
||||
@@ -589,8 +589,8 @@
|
||||
<tabstop>cb_ByFamily</tabstop>
|
||||
<tabstop>cb_ByCombinedCode</tabstop>
|
||||
<tabstop>cb_ByVtol</tabstop>
|
||||
<tabstop>cb_ByForceMilitary</tabstop>
|
||||
<tabstop>cb_ByForceCivilian</tabstop>
|
||||
<tabstop>cb_ByMilitary</tabstop>
|
||||
<tabstop>cb_ByCivilian</tabstop>
|
||||
<tabstop>cb_CategoryGlider</tabstop>
|
||||
<tabstop>cb_CategoryMilitaryAircraft</tabstop>
|
||||
<tabstop>cb_CategorySmallAircraft</tabstop>
|
||||
|
||||
@@ -196,8 +196,8 @@ namespace BlackMisc
|
||||
static const QString icaoAircraft("by ICAO aircraft first");
|
||||
static const QString icaoAirline("by ICAO airline first");
|
||||
static const QString family("by family");
|
||||
static const QString forceMil("force military");
|
||||
static const QString forceCiv("force civilian");
|
||||
static const QString military("by military");
|
||||
static const QString civilian("by civilian");
|
||||
static const QString vtol("VTOL");
|
||||
static const QString livery("by livery");
|
||||
static const QString combined("by combined code");
|
||||
@@ -228,8 +228,8 @@ namespace BlackMisc
|
||||
case ByCombinedType: return combined;
|
||||
case ByIcaoOrderAircraftFirst: return icaoAircraft;
|
||||
case ByIcaoOrderAirlineFirst: return icaoAirline;
|
||||
case ByForceCivilian: return forceCiv;
|
||||
case ByForceMilitary: return forceMil;
|
||||
case ByCivilian: return civilian;
|
||||
case ByMilitary: return military;
|
||||
case ByVtol: return vtol;
|
||||
case ByCategoryGlider: return categoryGlider;
|
||||
case ByCategoryMilitary: return categoryMilitary;
|
||||
@@ -263,8 +263,8 @@ namespace BlackMisc
|
||||
if (mode.testFlag(ByFamily)) { modes << modeFlagToString(ByFamily); }
|
||||
if (mode.testFlag(ByLivery)) { modes << modeFlagToString(ByLivery); }
|
||||
if (mode.testFlag(ByCombinedType)) { modes << modeFlagToString(ByCombinedType); }
|
||||
if (mode.testFlag(ByForceCivilian)) { modes << modeFlagToString(ByForceCivilian); }
|
||||
if (mode.testFlag(ByForceMilitary)) { modes << modeFlagToString(ByForceMilitary); }
|
||||
if (mode.testFlag(ByCivilian)) { modes << modeFlagToString(ByCivilian); }
|
||||
if (mode.testFlag(ByMilitary)) { modes << modeFlagToString(ByMilitary); }
|
||||
if (mode.testFlag(ByCategoryGlider)) { modes << modeFlagToString(ByCategoryGlider); }
|
||||
if (mode.testFlag(ByCategoryMilitary)) { modes << modeFlagToString(ByCategoryMilitary); }
|
||||
if (mode.testFlag(ByCategorySmallAircraft)) { modes << modeFlagToString(ByCategorySmallAircraft); }
|
||||
@@ -301,8 +301,8 @@ namespace BlackMisc
|
||||
CAircraftMatcherSetup::MatchingMode CAircraftMatcherSetup::matchingMode(
|
||||
bool revModelString, bool revLiveryIds,
|
||||
bool byModelString, bool byIcaoDataAircraft1st, bool byIcaoDataAirline1st, bool byFamily, bool byLivery, bool byCombinedType,
|
||||
bool byForceMilitary, bool byForceCivilian, bool byVtol,
|
||||
bool byGliderCategory, bool byMilitaryCategory, bool bySmallAircraftCategory,
|
||||
bool byMilitary, bool byCivilian, bool byVtol,
|
||||
bool byGliderCategory, bool byMilitaryCategory, bool bySmallAircraftCategory,
|
||||
bool scoreIgnoreZeros, bool scorePreferColorLiveries,
|
||||
bool excludeNoDbData, bool excludeNoExcluded,
|
||||
bool modelVerification, bool modelVerificationWarnError,
|
||||
@@ -316,8 +316,8 @@ namespace BlackMisc
|
||||
if (byFamily) { mode |= ByFamily; }
|
||||
if (byLivery) { mode |= ByLivery; }
|
||||
if (byCombinedType) { mode |= ByCombinedType; }
|
||||
if (byForceMilitary) { mode |= ByForceMilitary; }
|
||||
if (byForceCivilian) { mode |= ByForceCivilian; }
|
||||
if (byMilitary) { mode |= ByMilitary; }
|
||||
if (byCivilian) { mode |= ByCivilian; }
|
||||
if (byVtol) { mode |= ByVtol; }
|
||||
if (byGliderCategory) { mode |= ByCategoryGlider; }
|
||||
if (byMilitaryCategory) { mode |= ByCategoryMilitary; }
|
||||
|
||||
@@ -39,9 +39,9 @@ namespace BlackMisc
|
||||
ByLivery = 1 << 3,
|
||||
ByCombinedType = 1 << 4,
|
||||
ByManufacturer = 1 << 5,
|
||||
ByForceMilitary = 1 << 6, //!< military (in) will only search in military
|
||||
ByForceCivilian = 1 << 7, //!< civilian (in) will only search in civilian
|
||||
ByMilitary = ByForceCivilian | ByForceMilitary,
|
||||
ByMilitary = 1 << 6, //!< military (in) will only search in military
|
||||
ByCivilian = 1 << 7, //!< civilian (in) will only search in civilian
|
||||
ByMilOrCivilian = ByCivilian | ByMilitary,
|
||||
ByVtol = 1 << 8,
|
||||
ByIcaoOrderAircraftFirst = (1 << 9) | ByIcaoData,
|
||||
ByIcaoOrderAirlineFirst = (1 << 10) | ByIcaoData,
|
||||
@@ -75,7 +75,7 @@ namespace BlackMisc
|
||||
|
||||
// --- others ---
|
||||
ModeNone = 0,
|
||||
ModeByFLags = ByMilitary | ByVtol,
|
||||
ModeByFLags = ByMilOrCivilian | ByVtol,
|
||||
|
||||
// default mode for set handling
|
||||
ModeDefaultSet = ModelSetRemoveFailedModel | ModelVerificationAtStartup | ModelFailoverIfNoModelCanBeAdded,
|
||||
|
||||
Reference in New Issue
Block a user