Allow autoscroll only if the UI is not hidden