Fix level 2 display

This commit is contained in:
Dan Paulat 2023-05-30 23:28:02 -05:00
parent b18491b2a0
commit 1b49e317e4
7 changed files with 96 additions and 18 deletions

View file

@ -119,7 +119,8 @@ void Level2ProductView::ConnectRadarProductManager()
{
if (record->radar_product_group() ==
common::RadarProductGroup::Level2 &&
record->time() == selected_time())
std::chrono::floor<std::chrono::seconds>(record->time()) ==
selected_time())
{
// If the data associated with the currently selected time is
// reloaded, update the view

View file

@ -146,6 +146,11 @@ RadarProductView::GetCfpMomentData() const
return std::tie(data, dataSize, componentSize);
}
std::chrono::system_clock::time_point RadarProductView::GetSelectedTime() const
{
return p->selectedTime_;
}
void RadarProductView::ComputeSweep()
{
logger_->debug("ComputeSweep()");

View file

@ -61,7 +61,8 @@ public:
virtual std::tuple<const void*, std::size_t, std::size_t>
GetMomentData() const = 0;
virtual std::tuple<const void*, std::size_t, std::size_t>
GetCfpMomentData() const;
GetCfpMomentData() const;
std::chrono::system_clock::time_point GetSelectedTime() const;
protected:
virtual void ConnectRadarProductManager() = 0;