Funnily enough, I was thinking that an adapted socket like that might be a cheaper (and easier) alternative to what I was planning. If I can find a back box made of non-brittle material, I could pop a flushmount IEC socket and Bob would be my uncle.
The idea, by the way is to have a small box mounted on the back of an active speaker that I could plug a Chromecast Audio into such that the speakers would only need mains power. I think A*I did something similar a while back with an "amp pack" on the back of a speaker.