I agree. You'd have to check function - if you're replacing the ECM, you need to make sure that it's compatible with the BCM fitted and the TCM in the gearbox (which SHOULD be the case, since they've used the same auto box for years and only changed it in 2011 for the 550 and 2012 for the D40 2.5).
The decision to shift the TF isn't made in the gearbox, in our cars it's driven by the command from the driver (switch) with a check for vehicle speed, ABS sensors intact - the transfer relays (in the box behind the battery) are then activated sending power to the servo mounted on the transfer case. The TCM (in the auto, it's with the valve body in the bottom of the box) doesn't have a say at all as far as I'm aware. It might feed data to the ECU in the form of expected output revolutions (-> expected speed, compare to ABS signal), current gear - from my understanding, it doesn't actually use the TCM to note the gear when selecting 4LO either, that's done purely by the Park/Neutral switch which is independent of the TCM.