diff --git a/src/blackgui/components/dbloadoverviewcomponent.cpp b/src/blackgui/components/dbloadoverviewcomponent.cpp
index 59262e03d..c1cd72fae 100644
--- a/src/blackgui/components/dbloadoverviewcomponent.cpp
+++ b/src/blackgui/components/dbloadoverviewcomponent.cpp
@@ -34,6 +34,9 @@ namespace BlackGui
ui->lbl_DatabaseUrl->setTextFormat(Qt::RichText);
ui->lbl_DatabaseUrl->setTextInteractionFlags(Qt::TextBrowserInteraction);
ui->lbl_DatabaseUrl->setOpenExternalLinks(true);
+ ui->lbl_SharedUrls->setTextFormat(Qt::RichText);
+ ui->lbl_SharedUrls->setTextInteractionFlags(Qt::TextBrowserInteraction);
+ ui->lbl_SharedUrls->setOpenExternalLinks(true);
connect(ui->tb_ReloadAircraft, &QToolButton::pressed, this, &CDbLoadOverviewComponent::ps_reloadPressed);
connect(ui->tb_ReloadAirlines, &QToolButton::pressed, this, &CDbLoadOverviewComponent::ps_reloadPressed);
@@ -43,8 +46,6 @@ namespace BlackGui
connect(ui->tb_ReloadModels, &QToolButton::pressed, this, &CDbLoadOverviewComponent::ps_reloadPressed);
connect(ui->tb_ReloadDistributors, &QToolButton::pressed, this, &CDbLoadOverviewComponent::ps_reloadPressed);
connect(sGui->getWebDataServices(), &CWebDataServices::dataRead, this, &CDbLoadOverviewComponent::ps_dataLoaded);
-
- // QTimer::singleShot(2000, this, &CDbLoadOverviewComponent::ps_setValues);
}
CDbLoadOverviewComponent::~CDbLoadOverviewComponent()
@@ -101,10 +102,34 @@ namespace BlackGui
ui->le_CountriesDbCount->setText(dbCountForEntity(CEntityFlags::CountryEntity));
ui->le_DistributorsDbCount->setText(dbCountForEntity(CEntityFlags::DistributorEntity));
- const QString urlHtml("Open DB");
- const QString url = sGui->getGlobalSetup().getDbHomePageUrl().getFullUrl();
- ui->lbl_DatabaseUrl->setText(urlHtml.arg(url));
+ ui->le_AircraftSharedFileTs->setText(sharedFileTimestampForEntity(CEntityFlags::AircraftIcaoEntity));
+ ui->le_AirlinesSharedFileTs->setText(sharedFileTimestampForEntity(CEntityFlags::AirlineIcaoEntity));
+ ui->le_AirportsSharedFileTs->setText(sharedFileTimestampForEntity(CEntityFlags::AirportEntity));
+ ui->le_LiveriesSharedFileTs->setText(sharedFileTimestampForEntity(CEntityFlags::LiveryEntity));
+ ui->le_ModelsSharedFileTs->setText(sharedFileTimestampForEntity(CEntityFlags::ModelEntity));
+ ui->le_CountriesSharedFileTs->setText(sharedFileTimestampForEntity(CEntityFlags::CountryEntity));
+ ui->le_DistributorsSharedFileTs->setText(sharedFileTimestampForEntity(CEntityFlags::DistributorEntity));
+
+ // DB URL
+ const QString dbUrlHtml("%2");
+ QString url = sGui->getGlobalSetup().getDbHomePageUrl().getFullUrl();
+ ui->lbl_DatabaseUrl->setText(dbUrlHtml.arg(url, url));
ui->lbl_DatabaseUrl->setToolTip(url);
+
+ // Shared URLs
+ const CUrlList sharedUrls(sGui->getGlobalSetup().getSwiftSharedUrls());
+ const QString sharedUrlHtml("%2");
+
+ QString sharedUrlsHtml;
+ for (const CUrl &url : sharedUrls)
+ {
+ sharedUrlsHtml += sharedUrlHtml.arg(url.getFullUrl(), url.getHost());
+ sharedUrlsHtml += " ";
+ }
+ ui->lbl_SharedUrls->setText(sharedUrlsHtml.trimmed());
+ ui->lbl_SharedUrls->setToolTip(sharedUrls.toQString());
+
+ // Indicator
if (this->m_loadIndicator) { this->m_loadIndicator->stopAnimation(); }
}
@@ -148,6 +173,12 @@ namespace BlackGui
return c < 0 ? "-" : QString::number(c);
}
+ QString CDbLoadOverviewComponent::sharedFileTimestampForEntity(CEntityFlags::Entity entity)
+ {
+ const QDateTime ts = sGui->getWebDataServices()->getSharedFileTimestamp(entity);
+ return formattedTimestamp(ts);
+ }
+
QString CDbLoadOverviewComponent::dbCountForEntity(CEntityFlags::Entity entity)
{
const int c = sGui->getWebDataServices()->getDbInfoCount(entity);
@@ -164,10 +195,15 @@ namespace BlackGui
if (this->m_reloading) { return; }
QObject *sender = QObject::sender();
CEntityFlags::Entity entity = CEntityFlags::singleEntityByName(sender->objectName());
+
+ // DB entities
CEntityFlags::Entity triggeredEntity = sGui->getWebDataServices()->triggerReloadFromDb(entity);
if (triggeredEntity == CEntityFlags::NoEntity) { return; }
this->m_reloading = true;
this->showLoading();
+
+ // shared files ts
+ sGui->getWebDataServices()->triggerLoadingOfSharedFilesHeaders(entity);
}
void CDbLoadOverviewComponent::ps_dataLoaded(CEntityFlags::Entity entity, CEntityFlags::ReadState state, int number)
diff --git a/src/blackgui/components/dbloadoverviewcomponent.h b/src/blackgui/components/dbloadoverviewcomponent.h
index 7a9d32e38..9d55431cb 100644
--- a/src/blackgui/components/dbloadoverviewcomponent.h
+++ b/src/blackgui/components/dbloadoverviewcomponent.h
@@ -63,6 +63,9 @@ namespace BlackGui
//! Formatted count for entity
static QString cacheCountForEntity(BlackMisc::Network::CEntityFlags::Entity entity);
+ //! Formatted ts for entity
+ static QString sharedFileTimestampForEntity(BlackMisc::Network::CEntityFlags::Entity entity);
+
//! Formatted count for entity
static QString dbCountForEntity(BlackMisc::Network::CEntityFlags::Entity entity);
diff --git a/src/blackgui/components/dbloadoverviewcomponent.ui b/src/blackgui/components/dbloadoverviewcomponent.ui
index 556531b51..6f59e032a 100644
--- a/src/blackgui/components/dbloadoverviewcomponent.ui
+++ b/src/blackgui/components/dbloadoverviewcomponent.ui
@@ -6,8 +6,8 @@
0
0
- 482
- 216
+ 640
+ 279
@@ -29,217 +29,27 @@
4
- -
-
-
- true
-
-
- count
-
-
-
- -
-
-
- true
-
-
- count
-
-
-
- -
-
-
- true
-
-
- cache ts
-
-
-
- -
-
-
- true
-
-
- DB ts
-
-
-
- -
-
-
- Airports:
-
-
-
- -
-
-
+
-
+
+
- 48
- 16777215
+ 0
+ 50
-
-
-
-
- :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+ Shared URLs will go here
- -
-
-
-
- 48
- 16777215
-
-
+
-
+
-
-
-
-
- :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+ DB URL will go here .....
- -
-
-
-
- 48
- 16777215
-
-
-
-
-
-
-
- :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
-
-
-
- -
-
-
-
- 48
- 16777215
-
-
-
-
-
-
-
- :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
-
-
-
- -
-
-
-
- 48
- 16777215
-
-
-
-
-
-
-
- :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
-
-
-
- -
-
-
-
- 48
- 16777215
-
-
-
-
- :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
-
-
-
- -
-
-
-
- 48
- 16777215
-
-
-
-
-
-
-
- :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
-
-
-
- -
-
-
- true
-
-
- cache ts
-
-
-
- -
-
-
- true
-
-
- DB ts
-
-
-
- -
-
-
- true
-
-
- count
-
-
-
- -
-
-
- true
-
-
- count
-
-
-
- -
-
-
- Liveries:
-
-
-
- -
+
-
true
@@ -249,46 +59,6 @@
- -
-
-
- true
-
-
- DB ts
-
-
-
- -
-
-
- true
-
-
- DB ts
-
-
-
- -
-
-
- true
-
-
- count
-
-
-
- -
-
-
- true
-
-
- cache ts
-
-
-
-
@@ -296,8 +66,24 @@
- -
-
+
-
+
+
+ true
+
+
+ count
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
true
@@ -306,6 +92,139 @@
+ -
+
+
+ true
+
+
+ count
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ DB ts
+
+
+
+ -
+
+
+ true
+
+
+ count
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ DB ts
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ cache ts
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ DB ts
+
+
+
+ -
+
+
+ Liveries:
+
+
+
+ -
+
+
+ true
+
+
+ count
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ cache ts
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ DB ts
+
+
+
-
@@ -313,6 +232,22 @@
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ cache ts
+
+
+
-
@@ -320,35 +255,21 @@
- -
-
-
- true
-
-
- cache ts
-
-
-
- -
-
-
- true
-
-
- cache ts
-
-
-
- -
+
-
DB ts:
- -
-
+
-
+
+
+
+ 100
+ 0
+
+
true
@@ -357,7 +278,39 @@
- -
+
-
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ cache ts
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ DB ts
+
+
+
+ -
true
@@ -367,8 +320,14 @@
- -
+
-
+
+
+ 100
+ 0
+
+
true
@@ -377,7 +336,14 @@
- -
+
-
+
+
+ Cache #:
+
+
+
+ -
true
@@ -387,26 +353,6 @@
- -
-
-
- true
-
-
- count
-
-
-
- -
-
-
- true
-
-
- DB ts
-
-
-
-
@@ -414,34 +360,7 @@
- -
-
-
- Cache #:
-
-
-
- -
-
-
- true
-
-
- DB ts
-
-
-
- -
-
-
- true
-
-
- count
-
-
-
- -
+
-
true
@@ -451,7 +370,7 @@
- -
+
-
true
@@ -461,21 +380,83 @@
- -
+
-
+
+
+ true
+
+
+ count
+
+
+
+ -
DB #:
- -
+
-
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ DB ts
+
+
+
+ -
Cache ts:
- -
+
-
+
+
+ true
+
+
+ count
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ File ts
+
+
+
+ -
+
+
+ true
+
+
+ count
+
+
+
+ -
true
@@ -485,13 +466,67 @@
- -
-
+
-
+
+
+
+ 100
+ 0
+
+
true
- count
+ File ts
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ File ts
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ File ts
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ File ts
@@ -502,10 +537,383 @@
- -
-
+
-
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ File ts
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ cache ts
+
+
+
+ -
+
+
+
+ 100
+ 0
+
+
+
+ true
+
+
+ File ts
+
+
+
+ -
+
- URL will go here .....
+ DB URL:
+
+
+
+ -
+
+
+ true
+
+
+ count
+
+
+
+ -
+
+
+ Shared ts:
+
+
+
+ -
+
+
+ Shared:
+
+
+
+ -
+
+
+ Airports:
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from shared files
+
+
+ ...
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from shared files
+
+
+ ...
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from shared files
+
+
+ ...
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from shared files
+
+
+ ...
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from shared files
+
+
+ ...
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from shared files
+
+
+ ...
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+ Shared
+
+
+ Shr.:
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from shared files
+
+
+ ...
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+ DB:
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from database
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from database
+
+
+
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from database
+
+
+
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from database
+
+
+
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from database
+
+
+
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from database
+
+
+
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
+
+
+
+ -
+
+
+
+ 48
+ 16777215
+
+
+
+ refresh from database
+
+
+
+
+
+
+ :/pastel/icons/pastel/16/arrow-refresh.png:/pastel/icons/pastel/16/arrow-refresh.png
diff --git a/src/swiftlauncher/swiftlauncher.cpp b/src/swiftlauncher/swiftlauncher.cpp
index 56c992740..57248b2cd 100644
--- a/src/swiftlauncher/swiftlauncher.cpp
+++ b/src/swiftlauncher/swiftlauncher.cpp
@@ -40,6 +40,7 @@ CSwiftLauncher::CSwiftLauncher(QWidget *parent) :
{
ui->setupUi(this);
this->init();
+ ui->tb_Launcher->setCurrentIndex(0);
connect(ui->pb_CheckForUpdates, &QPushButton::pressed, this, &CSwiftLauncher::ps_loadSetup);
connect(ui->tb_SwiftCore, &QPushButton::pressed, this, &CSwiftLauncher::ps_startButtonPressed);
connect(ui->tb_SwiftMappingTool, &QPushButton::pressed, this, &CSwiftLauncher::ps_startButtonPressed);
diff --git a/src/swiftlauncher/swiftlauncher.ui b/src/swiftlauncher/swiftlauncher.ui
index 9379bfadc..2de9ea7fd 100644
--- a/src/swiftlauncher/swiftlauncher.ui
+++ b/src/swiftlauncher/swiftlauncher.ui
@@ -78,7 +78,7 @@
-
- 4
+ 2
6
@@ -181,8 +181,8 @@
0
0
- 390
- 326
+ 376
+ 331
@@ -204,6 +204,83 @@
4
+
-
+
+
+ GUI and core
+
+
+ bg_CoreMode
+
+
+
+ -
+
+
+ GUI and core
+
+
+ bg_CoreMode
+
+
+
+ -
+
+
+ standalone
+
+
+ true
+
+
+ bg_CoreMode
+
+
+
+ -
+
+
+
+
+
+ :/launcher/icons/swiftGUIandCore115x85.png
+
+
+
+ -
+
+
+ Audio on GUI side
+
+
+
+ -
+
+
+
+
+
+ :/launcher/icons/swiftGUIandCore115x85.png
+
+
+
+ -
+
+
+
+
+
+ :/launcher/icons/swiftNormal61x100.png
+
+
+
+ -
+
+
+ Audio on core side
+
+
+
-
@@ -322,81 +399,23 @@
- -
-
-
- GUI and core
-
-
- bg_CoreMode
-
-
-
- -
-
-
-
-
-
- :/launcher/icons/swiftGUIandCore115x85.png
-
-
-
- -
-
-
- GUI and core
-
-
- bg_CoreMode
-
-
-
- -
-
-
-
-
-
- :/launcher/icons/swiftGUIandCore115x85.png
-
-
-
- -
-
-
- standalone
-
-
- true
-
-
- bg_CoreMode
-
-
-
- -
-
-
- Audio on GUI side
-
-
-
- -
-
-
-
-
-
- :/launcher/icons/swiftNormal61x100.png
-
-
-
- -
-
-
- Audio on core side
-
+
-
+
+
+
-
+
+
+ Qt::Vertical
+
+
+
+ 20
+ 40
+
+
+
+
+
@@ -837,8 +856,8 @@ p, li { white-space: pre-wrap; }
-
+