window onsize listener and change function