Power would only be drawn from the source with the higher voltage.
S0 9V wallwart when plugged in, and 7.4V battery when not.
Find a schottky diode, one with a lower drop, vs 1N4004 with 1.1V drop.
Example:
I think you also want R1 between the Output and Adjust, not Input.
Don't forget caps as well.