Added improvement in autosizing for the navigation bar