Side Islamic swimmer

I came across this for the first time in Turkey, women who have specially adapted dresses for swimming! They seemed to enjoy the attention they received and I wonder if it was only for that and not for religious reasons.