He may or may not be acting virtuously, but at least he is not acting against the cardinal virtue of temperance, of which chastity is a part. Temperance is a negative virtue: its sole office is to restrain: it never urges any one to any gratification of appetite: "for inclination to the proper objects of any faculties does not belong to the habit, but rather is of the very essence of the said faculties" (Sum. Theol. 1a-2ae q. 31, art. 1, in corp.) Cf. Arriaga De habitibus et virtutibus, disp. 36, nn. 4, 5, 6; and Ethics and Natural Law, pp. 91, 95, ed. 3, a curious and little noticed point of Ethics.
Of God and His Creatures: 3.137