I always thought it was a EU/German regulation, because they just dim the light on flights to Germany. Never happened on an US/Ex-US flight.
The cabin crew said something about "to prevent light pollution for the citizens living near the airport".
Not sure if this is the truth.