clang tidy/format fixes for add_custom_layer_dialog

This commit is contained in:
AdenKoperczak 2025-03-25 10:35:01 -04:00
parent a7c6be2bab
commit f5ab6f3ef7
4 changed files with 5 additions and 4 deletions

View file

@ -539,7 +539,8 @@ void SettingsInterface<T>::EnableTrimming(bool trimmingEnabled)
} }
template<class T> template<class T>
void SettingsInterface<T>::SetInvalidTooltip(std::optional<std::string> tooltip) void SettingsInterface<T>::SetInvalidTooltip(
const std::optional<std::string>& tooltip)
{ {
p->invalidTooltip_ = std::move(tooltip); p->invalidTooltip_ = std::move(tooltip);
} }

View file

@ -136,7 +136,7 @@ public:
* *
* @param tooltip the tooltip to be displayed * @param tooltip the tooltip to be displayed
*/ */
void SetInvalidTooltip(std::optional<std::string> tooltip); void SetInvalidTooltip(const std::optional<std::string>& tooltip);
private: private:
class Impl; class Impl;

View file

@ -49,7 +49,7 @@ void CustomLayerDialogImpl::handle_mapChanged(QMapLibre::Map::MapChange change)
self_->ui->layerListWidget->clear(); self_->ui->layerListWidget->clear();
self_->ui->layerListWidget->addItems(layerIds); self_->ui->layerListWidget->addItems(layerIds);
std::string symbologyLayer = util::maplibre::FindMapSymbologyLayer( const std::string symbologyLayer = util::maplibre::FindMapSymbologyLayer(
layerIds, {customStyleDrawLayer}); layerIds, {customStyleDrawLayer});
const auto& symbologyItems = self_->ui->layerListWidget->findItems( const auto& symbologyItems = self_->ui->layerListWidget->findItems(

View file

@ -137,7 +137,7 @@ std::string FindMapSymbologyLayer(const QStringList& styleLayers,
[&layer](const std::string& styleLayer) -> bool [&layer](const std::string& styleLayer) -> bool
{ {
// Perform case-insensitive matching // Perform case-insensitive matching
RE2 re {"(?i)" + styleLayer}; const RE2 re {"(?i)" + styleLayer};
if (re.ok()) if (re.ok())
{ {
return RE2::FullMatch(layer, re); return RE2::FullMatch(layer, re);