add support for window resize