It’s debatable whether the name Ernest, used punningly by Wilde in his most famous play The Importance of Being Earnest, was chosen as a late Victorian code word for “gay”.
For instance, the Wildean academic, John Stokes, suggests here this may be true “since the word ‘Earnest’ bears a euphonious relation to the [gender-variant] term Uranian”—presumably in the sound of its continental equivalents. 
On the other hand, the actor, Sir Donald Sinden, who both knew and consulted Lord Alfred Douglas and Sir John Gielgud on the point, once wrote to The Times to dispute the suggestion. 
However, whether the words Ernest and Earnest are homosexual or merely homophonic, one thing is clear.
The choice of names, and particularly the name Ernest, formed part of a gay literary subtext close to Wilde in the 1890s.
The Judas Kiss focuses on two crucial moments in Oscar Wilde’s life
I was asked by the Brooklyn Academy of Music (BAM) to provide an article for their blog in anticipation of David Hare’s forthcoming play The Judas Kiss.
It isrepublished here, slightly amended, followed by a link to a moving article by Ruper Everett on playing Oscar.
The Judas Kiss, coming to the BAM Harvey Theater May 11—Jun 12, marks a historic return of the Irish poet, dramatist, and wit Oscar Wilde. This is not, of course, a return of Wilde the playwright, whose works have been staged several times at BAM over the years. It is a return in the sense of the reappearance of Wilde in person.
This is significant because no one has appeared as Oscar Wilde at BAM since Wilde himself spoke there 134 years ago on a nationwide lecture tour. The performance by Rupert Everett, who plays Wilde, is a fitting parallel because Oscar was also playing a part—masquerading as the poster boy for Gilbert and Sullivan’s Patience, a comic opera poking fun at the aesthetic movement.