Added a callback function setting for when the modal opens.