fix bug initializing the view with empty screen width/height