public function addDialogListener(listener:Function):GVShareDispatcher
Convenience method that adds an event listener for when a Social Composer or Generic Sharing dialog request is completed. This listener will be a weak reference and automatically removed after dispatch. For backwards compatibility, GoViral.goViral
will also dispatch the related event.
The listener parameter should take the form of function(e:GVShareEvent) {}
. You may check the value of e.type
which will be either GVShareEvent.GENERIC_MESSAGE_SHARED
, GVShareEvent.SOCIAL_COMPOSER_FINISHED
, or GVShareEvent.SOCIAL_COMPOSER_CANCELED
, depending on how the dialog was completed. The property e.socialServiceType
will be the related constant from GVSocialServiceType
if the dialog was a social composer dialog.
Parameters
| listener:Function — the event listener function, should take GVFacebookEvent as a parameter
|
ReturnsSee also
Event Object Type: com.milkmangames.nativeextensions.events.GVShareEvent
Dispatched after a Generic message sharing intent has been completed
Event Object Type: com.milkmangames.nativeextensions.events.GVShareEvent
Dispatched when a social composer view is canceled
Event Object Type: com.milkmangames.nativeextensions.events.GVShareEvent
Dispatched when a social composer view is finished