To shut the door on something means to eliminate the opportunity for it, which is what he did by letting her go.
Consider the statement "He would eliminate the opportunity for his charming episode with her and let her go.". Is the statement "He would shut the door on his charming episode with her and let her go." false? Yes/no/unknown