Add Add support for widget caching to FilterSelectionWidget

This commit is contained in:
WarmUpTill
2025-05-21 11:27:33 +02:00
committed by WarmUpTill
parent 9805601c07
commit 1381654fed
2 changed files with 10 additions and 0 deletions

View File

@@ -289,6 +289,13 @@ void FilterSelectionWidget::SetFilter(const SourceSelection &source,
_currentSelection = filter;
}
void FilterSelectionWidget::showEvent(QShowEvent *event)
{
FilterComboBox::showEvent(event);
const QSignalBlocker b(this);
Reset();
}
void FilterSelectionWidget::SourceChanged(const SourceSelection &source)
{
if (source == _source) {

View File

@@ -45,6 +45,9 @@ public:
bool addVariables = true);
void SetFilter(const SourceSelection &, const FilterSelection &);
protected:
void showEvent(QShowEvent *event) override;
signals:
void FilterChanged(const FilterSelection &);