Fix window resize & warnings