clang tidy/format fixes for update_tdwr_products

This commit is contained in:
AdenKoperczak 2025-03-14 13:18:00 -04:00
parent 6509fc7043
commit dc72e9fbfc
4 changed files with 8 additions and 10 deletions

View file

@ -186,7 +186,7 @@ public:
std::shared_mutex awipsProductMutex_; std::shared_mutex awipsProductMutex_;
common::Level3ProductCategoryMap categoryMap_; common::Level3ProductCategoryMap categoryMap_;
std::shared_mutex categoryMapMutex_; std::shared_mutex categoryMapMutex_;
std::string currentAwipsId_ {}; std::string currentAwipsId_ {};
QAction* currentProductTiltAction_ {nullptr}; QAction* currentProductTiltAction_ {nullptr};
@ -327,7 +327,7 @@ void Level3ProductsWidgetImpl::SelectProductCategory(
{ {
UpdateCategorySelection(category); UpdateCategorySelection(category);
std::shared_lock lock {categoryMapMutex_}; const std::shared_lock lock {categoryMapMutex_};
Q_EMIT self_->RadarProductSelected( Q_EMIT self_->RadarProductSelected(
common::RadarProductGroup::Level3, common::RadarProductGroup::Level3,
@ -342,7 +342,7 @@ void Level3ProductsWidget::UpdateAvailableProducts(
// Save the category map // Save the category map
{ {
std::unique_lock lock {p->categoryMapMutex_}; const std::unique_lock lock {p->categoryMapMutex_};
p->categoryMap_ = updatedCategoryMap; p->categoryMap_ = updatedCategoryMap;
} }

View file

@ -45,7 +45,7 @@ public:
void ComputeCoordinates( void ComputeCoordinates(
const std::shared_ptr<wsr88d::rpg::GenericRadialDataPacket>& radialData, const std::shared_ptr<wsr88d::rpg::GenericRadialDataPacket>& radialData,
bool smoothingEnabled, bool smoothingEnabled,
float gateSize); float gateSize);
[[nodiscard]] inline std::uint8_t [[nodiscard]] inline std::uint8_t
@ -357,9 +357,7 @@ void Level3RadialView::ComputeSweep()
// Compute gate size (number of base gates per bin) // Compute gate size (number of base gates per bin)
const std::uint16_t gateSize = std::max<std::uint16_t>( const std::uint16_t gateSize = std::max<std::uint16_t>(
1, 1, dataMomentInterval / static_cast<std::uint16_t>(gateLength));
dataMomentInterval /
static_cast<std::uint16_t>(gateLength));
// Compute gate range [startGate, endGate) // Compute gate range [startGate, endGate)
std::uint16_t startGate = 0; std::uint16_t startGate = 0;
@ -540,7 +538,7 @@ Level3RadialView::Impl::RemapDataMoment(std::uint8_t dataMoment) const
void Level3RadialView::Impl::ComputeCoordinates( void Level3RadialView::Impl::ComputeCoordinates(
const std::shared_ptr<wsr88d::rpg::GenericRadialDataPacket>& radialData, const std::shared_ptr<wsr88d::rpg::GenericRadialDataPacket>& radialData,
bool smoothingEnabled, bool smoothingEnabled,
float gateSize) float gateSize)
{ {
logger_->debug("ComputeCoordinates()"); logger_->debug("ComputeCoordinates()");

View file

@ -74,7 +74,7 @@ Level2Product GetLevel2Product(const std::string& name);
const std::string& GetLevel3CategoryName(Level3ProductCategory category); const std::string& GetLevel3CategoryName(Level3ProductCategory category);
const std::string& GetLevel3CategoryDescription(Level3ProductCategory category); const std::string& GetLevel3CategoryDescription(Level3ProductCategory category);
std::string std::string
GetLevel3CategoryDefaultProduct(Level3ProductCategory category, GetLevel3CategoryDefaultProduct(Level3ProductCategory category,
const Level3ProductCategoryMap& categoryMap); const Level3ProductCategoryMap& categoryMap);
Level3ProductCategory GetLevel3Category(const std::string& categoryName); Level3ProductCategory GetLevel3Category(const std::string& categoryName);
Level3ProductCategory Level3ProductCategory

View file

@ -309,7 +309,7 @@ GetLevel3CategoryDefaultProduct(Level3ProductCategory category,
} }
const auto& productsSiteHas = productsIt->second; const auto& productsSiteHas = productsIt->second;
const auto& productList = level3CategoryProductList_.at(category); const auto& productList = level3CategoryProductList_.at(category);
for (auto& product : productList) for (auto& product : productList)
{ {
const auto& tiltsIt = productsSiteHas.find(product); const auto& tiltsIt = productsSiteHas.find(product);