Invoke function on thickbox unloading in WP