Makes addLoadingIcon optional when opening a dialog