mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-24 07:55:35 +08:00
Some fixes for interpolation setups
* added missing signal * refresh list on reload button press * display pitch value * list ctor for single object
This commit is contained in:
committed by
Mat Sutcliffe
parent
9b031bb582
commit
148368ca0c
@@ -34,15 +34,15 @@ namespace BlackGui
|
||||
ui->tvp_InterpolationSetup->menuAddItems(CInterpolationSetupView::MenuRemoveSelectedRows);
|
||||
|
||||
connect(ui->pb_RenderingSetup, &QPushButton::clicked, this, &CInterpolationSetupComponent::requestRenderingRestrictionsWidget);
|
||||
connect(ui->pb_Save, &QPushButton::clicked, this, &CInterpolationSetupComponent::saveSetup);
|
||||
connect(ui->pb_DeleteOrReset, &QPushButton::clicked, this, &CInterpolationSetupComponent::removeOrResetSetup);
|
||||
connect(ui->pb_Reload, &QPushButton::clicked, this, &CInterpolationSetupComponent::reloadSetup);
|
||||
connect(ui->tvp_InterpolationSetup, &CInterpolationSetupView::doubleClicked, this, &CInterpolationSetupComponent::onRowDoubleClicked);
|
||||
connect(ui->tvp_InterpolationSetup, &CInterpolationSetupView::modelChanged, this, &CInterpolationSetupComponent::onModelChanged, Qt::QueuedConnection);
|
||||
connect(ui->pb_Save, &QPushButton::clicked, this, &CInterpolationSetupComponent::saveSetup);
|
||||
connect(ui->pb_DeleteOrReset, &QPushButton::clicked, this, &CInterpolationSetupComponent::removeOrResetSetup);
|
||||
connect(ui->pb_Reload, &QPushButton::clicked, this, &CInterpolationSetupComponent::reloadSetup, Qt::QueuedConnection);
|
||||
connect(ui->tvp_InterpolationSetup, &CInterpolationSetupView::doubleClicked, this, &CInterpolationSetupComponent::onRowDoubleClicked);
|
||||
connect(ui->tvp_InterpolationSetup, &CInterpolationSetupView::modelChanged, this, &CInterpolationSetupComponent::onModelChanged, Qt::QueuedConnection);
|
||||
connect(ui->tvp_InterpolationSetup, &CInterpolationSetupView::modelDataChanged, this, &CInterpolationSetupComponent::onModelChanged, Qt::QueuedConnection);
|
||||
connect(ui->tvp_InterpolationSetup, &CInterpolationSetupView::objectsDeleted, this, &CInterpolationSetupComponent::onObjectsDeleted, Qt::QueuedConnection);
|
||||
connect(ui->tvp_InterpolationSetup, &CInterpolationSetupView::objectsDeleted, this, &CInterpolationSetupComponent::onObjectsDeleted, Qt::QueuedConnection);
|
||||
connect(ui->rb_Callsign, &QRadioButton::released, this, &CInterpolationSetupComponent::onModeChanged);
|
||||
connect(ui->rb_Global, &QRadioButton::released, this, &CInterpolationSetupComponent::onModeChanged);
|
||||
connect(ui->rb_Global, &QRadioButton::released, this, &CInterpolationSetupComponent::onModeChanged);
|
||||
if (sGui && sGui->getIContextSimulator())
|
||||
{
|
||||
connect(sGui->getIContextSimulator(), &IContextSimulator::interpolationAndRenderingSetupChanged, this, &CInterpolationSetupComponent::onSetupChanged, Qt::QueuedConnection);
|
||||
@@ -106,9 +106,15 @@ namespace BlackGui
|
||||
// void
|
||||
}
|
||||
|
||||
void CInterpolationSetupComponent::onReloadSetup()
|
||||
{
|
||||
this->reloadSetup();
|
||||
this->displaySetupsPerCallsign();
|
||||
}
|
||||
|
||||
void CInterpolationSetupComponent::reloadSetup()
|
||||
{
|
||||
const bool global = (this->getSetupMode() == CInterpolationSetupComponent::SetupGlobal);
|
||||
const bool global = (this->getSetupMode() == CInterpolationSetupComponent::SetupGlobal);
|
||||
const bool overlay = QObject::sender() == ui->pb_Reload;
|
||||
if (!this->checkPrerequisites(!global, overlay)) { return; }
|
||||
if (global)
|
||||
@@ -268,7 +274,7 @@ namespace BlackGui
|
||||
CInterpolationSetupList setups = ui->tvp_InterpolationSetup->container();
|
||||
setups.removeByCallsigns(deletedSetups.getCallsigns());
|
||||
const bool set = this->setSetupsToContext(setups, true);
|
||||
Q_UNUSED(set);
|
||||
Q_UNUSED(set)
|
||||
}
|
||||
}
|
||||
} // ns
|
||||
|
||||
Reference in New Issue
Block a user