Aren't all showtunes, by definition, gay? Well, let's give a little historical credit to Rodgers and Hammerstein and Cole Porter for gay subtext that may well have been text:
The first would have to be "We Kiss in a Shadow," which definitively expressed the longing of the pre-Stonewall gay experience.
Next would be "I Enjoy Being a Girl," which definitively expressed the outrageousness of the pre-Stonewall drag experience.
Then "You're the Top," which cleverly expressed in coded language the 1930s idea of sexual role-playing.
But the winner would have to be Cole Porter's "Farming," from 1941's "Let Face It," in which Danny Kaye sang to Vivian Vance:
"Don't inquire of Georgie Raft
Why his cow has never calfed.
Georgie's bull is beautiful
But he's gay!"