> I think structureChanged() could possibly be used for other stuff, too, > though it's not at present. The call in ControlToc::updateBackend() goes > to the current buffer, though, which may have its own TOC, right?
void ControlToc::updateBackend() { kernel().buffer().getMasterBuffer()->tocBackend().update(); kernel().buffer().structureChanged(); } is fine. Because it updates tocbackend from the master buffer; and then fires structureChanged() from the current buffer, which is always connected. structureChanged will update the TocPanel, with the correctly updated Toc. It would be wrong to call kernel().buffer().getMasterBuffer()->structureChanged(); Cheers, Bo