Adding improved support for auto-layout to the badge view.