Re: Cross-coupling comboboxes

> There may be a better fix. It would be nice if calling clear() on the
> model didn't invoke the signal_changed of BOTH comboboxes 328 times each

Blocking the signal is another way to do it. That may or may not have any quantitative difference in speed (from sigc not having to call your handler), but it might well lead to nicer handler code if you don't have to check for all the abnormal conditions, by simply blocking so it's never called in such cases instead.

Another idea I have is to unset the model from the ComboBoxes before clearing the model, then reassociate it with them afterwards. That might result in only notify::model being emitted, rather than all the ::changed.

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]