mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-30 14:50:05 +00:00
Add NoUpdateReason of NotAvailable, driven by ProductNotAvailable
This commit is contained in:
parent
449d8cb796
commit
a306fb4363
8 changed files with 49 additions and 16 deletions
|
|
@ -121,9 +121,12 @@ void Level3RasterView::ComputeSweep()
|
|||
std::shared_ptr<wsr88d::rpg::Level3Message> message;
|
||||
std::chrono::system_clock::time_point requestedTime {selected_time()};
|
||||
std::chrono::system_clock::time_point foundTime;
|
||||
std::tie(message, foundTime, std::ignore) =
|
||||
types::RadarProductLoadStatus loadStatus {};
|
||||
std::tie(message, foundTime, loadStatus) =
|
||||
radarProductManager->GetLevel3Data(GetRadarProductName(), requestedTime);
|
||||
|
||||
set_load_status(loadStatus);
|
||||
|
||||
// If a different time was found than what was requested, update it
|
||||
if (requestedTime != foundTime)
|
||||
{
|
||||
|
|
@ -133,7 +136,10 @@ void Level3RasterView::ComputeSweep()
|
|||
if (message == nullptr)
|
||||
{
|
||||
logger_->debug("Level 3 data not found");
|
||||
Q_EMIT SweepNotComputed(types::NoUpdateReason::NotLoaded);
|
||||
Q_EMIT SweepNotComputed(
|
||||
loadStatus == types::RadarProductLoadStatus::ProductNotAvailable ?
|
||||
types::NoUpdateReason::NotAvailable :
|
||||
types::NoUpdateReason::NotLoaded);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue