dockControl.putProperty(StackDockStation.IMMUTABLE_SELECTION_INDEX, true);
// ... and don't automatically put the focus on him
dockControl.getLocationManager().getNormalMode().setShouldAutoFocus(false);
However, there is still a problem: when the new dockable is added, the current one now stays selected (IMMUTABLE_SELECT_INDEX), the new one doesn’t get the focus (setShouldAutoFocus(false)), BUT the old tab that had the focus loses the focus…
You can try adding a “CVetoFocusListener” to the CControl (control.addVetoFocusListener). The veto-focus-listener can stop DockingFrames from moving around the focus. You just need to remember to add the listener before making your Dockable visible, and then remove it afterwards.
That solution will not work in all cases, but let me know whether it is good enough for your use case.