Ekran boyutu (veya cihazın yatay/dikey dönmesi) değiştiğinde oranı günceller.
void updateAspectRatio(double width, double height) { if (height > 0) { aspectRatio = width / height; } }