Added bounds for window resizing.