mirror of
https://github.com/zyedidia/micro.git
synced 2026-03-11 07:02:44 +09:00
We should call the onSetActive callback not only when switching to another bufpane within the same tab but also when switching to another tab. Note on implementation details: - In SetActive() we need to check if the tab is not already active, to avoid calling onSetActive for an already active bufpane. - We cannot check that just by checking if the tab index passed to SetActive() is different from the current active tab index, since this index may remain the same even if the tab itself is different (in the case of removing a tab from the tablist). So we need to check the tab itself, not just the tab index. So we introduce the isActive field, to track the tab's active state in the Tab structure itself.