Questions regarding a comparator circuit coupling to an analog switch
Your switch is rated for 30mA of continuous current, thus I suggest that it might not be the best way to drive a 7805, depending on what you're trying to power.