According to the built-in help file:
“You can also double click a layer with a mask to enter mask editing mode. This is quicker and more convenient than using the switch.”
I tried this on a text layer – it doesn’t work. The text in the layer gets selected instead, ready for editing, but not the mask – nor does the switch change from “Layer” to “Mask” – I have to manually click the switch.
It works as described on an imported image.