Hi Simon,
What happens when you add both navigation trees to the layout?
Doesn't it automatically show/hide the correct one?
If not, you can create a non-persistent entity with a boolean to store the connectionstatus, and use a dataview with a nanoflowsource around them. In here you can use the IsConnectedToServer javascript action from the NanoflowCommons module to set the boolean. Then you can set conditional visibility based to show/hide the right navtree based on the boolean.