mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-02 23:25:53 +08:00
Ref T201, info component
* removed private signal, no longer needed as a newer signature does not require an input signal * timestamp format * fixed !entities.testFlag
This commit is contained in:
@@ -61,7 +61,6 @@ namespace BlackGui
|
||||
connect(ui->pb_LoadAllFromDB, &QPushButton::pressed, this, &CDbLoadOverviewComponent::loadAllFromDb);
|
||||
connect(ui->pb_LoadAllFromShared, &QPushButton::pressed, this, &CDbLoadOverviewComponent::loadAllFromShared);
|
||||
|
||||
connect(this, &CDbLoadOverviewComponent::ps_triggerDigestGuiUpdate, this, &CDbLoadOverviewComponent::setGuiValues);
|
||||
if (sGui->hasWebDataServices())
|
||||
{
|
||||
connect(sGui->getWebDataServices(), &CWebDataServices::dataRead, this, &CDbLoadOverviewComponent::dataLoaded);
|
||||
@@ -231,7 +230,7 @@ namespace BlackGui
|
||||
QString CDbLoadOverviewComponent::formattedTimestamp(const QDateTime &dateTime)
|
||||
{
|
||||
if (!dateTime.isValid()) { return "-"; }
|
||||
return dateTime.toUTC().toString("MM-dd hh:mm:ss");
|
||||
return dateTime.toUTC().toString("yy-MM-dd hh:mm:ss");
|
||||
}
|
||||
|
||||
QString CDbLoadOverviewComponent::cacheTimestampForEntity(CEntityFlags::Entity entity)
|
||||
@@ -327,7 +326,7 @@ namespace BlackGui
|
||||
{
|
||||
Q_UNUSED(number);
|
||||
if (!CEntityFlags::isFinishedReadState(state)) return;
|
||||
if (!entities.testFlag(CEntityFlags::SharedInfoObjectEntity) && entities.testFlag(CEntityFlags::DbInfoObjectEntity) && !CEntityFlags::anySwiftDbEntity(entities)) { return; }
|
||||
if (!entities.testFlag(CEntityFlags::SharedInfoObjectEntity) && !entities.testFlag(CEntityFlags::DbInfoObjectEntity) && !CEntityFlags::anySwiftDbEntity(entities)) { return; }
|
||||
m_loadInProgress = false;
|
||||
m_dsTriggerGuiUpdate.inputSignal();
|
||||
}
|
||||
|
||||
@@ -57,18 +57,13 @@ namespace BlackGui
|
||||
//! Load all from shared
|
||||
void loadAllFromShared();
|
||||
|
||||
signals:
|
||||
//! Trigger GUI update
|
||||
//! \private
|
||||
void ps_triggerDigestGuiUpdate();
|
||||
|
||||
protected:
|
||||
//! \copydoc QWidget::resizeEvent
|
||||
virtual void resizeEvent(QResizeEvent *event) override;
|
||||
|
||||
private:
|
||||
QScopedPointer<Ui::CDbLoadOverviewComponent> ui;
|
||||
BlackMisc::CDigestSignal m_dsTriggerGuiUpdate { this, &CDbLoadOverviewComponent::ps_triggerDigestGuiUpdate, &CDbLoadOverviewComponent::setGuiValues, 2500, 5 };
|
||||
BlackMisc::CDigestSignal m_dsTriggerGuiUpdate { this, &CDbLoadOverviewComponent::setGuiValues, 2500, 5 };
|
||||
bool m_loadInProgress = false; //!< data loading in progress
|
||||
bool m_setValuesInProgress = false; //!< setting values in progress, needed because of CNetworkUtils::canConnect check (processing events)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user