mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
filter: avoid unnecessary filter recalculations when loading set
When loading a stored filter set, we would get numerous constraintChanged signals, which caused filter recalculations. Use the ignoreSignal flag to prevent these. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
cd27e36b8f
commit
76cf251e59
1 changed files with 2 additions and 0 deletions
|
@ -89,8 +89,10 @@ void FilterWidget2::selectPreset(int i)
|
|||
|
||||
void FilterWidget2::loadPreset(int index)
|
||||
{
|
||||
ignoreSignal = true; // When reloading the filter UI, we get numerous constraintChanged signals. Ignore them.
|
||||
FilterData filter = filter_preset_get(index);
|
||||
setFilterData(filter);
|
||||
ignoreSignal = false;
|
||||
presetModified = false;
|
||||
updateFilter();
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue