Thanks, Paul. You're right; makeActiveEditor was not the cause of the
bug. We were setting focus somewhere else. If I remove all setFocus
calls and never interact with that window, then it behaves as expected.
However I still have a question about active parts in multi-window
situations.
I get the desired behavior if I bringToTop the editors in window 1 and
have some non-editor part active in window 1. I can interact all I want
in window 2 and bringing the editors to the top in window 1 never steals
focus because newPartContainer != activePartContainer.
On the other hand, I don't get the desired behavior if I do the following:
1. makeActive an editor in window 1
2. setActivePart in window 2 by interacting with it
3. Programatically bringToTop an editor in window 1. At this point,
newPartContainer == activePartContainer. This causes the editor in window
1 to be activated, and thus takes focus from window 2. Is this by design?