Remove code duplication between Confirm[Tooltip]Dialog and [Tooltip]Dialog. Refs #16930, refs #13279.