Packagecom.milkmangames.nativeextensions
Classpublic class GVMailDispatcher
InheritanceGVMailDispatcher Inheritance GVDispatcher Inheritance flash.events.EventDispatcher

GVMailDispatcher



Public Methods
 MethodDefined By
  
Convenience method that adds an event listener for when a send mail dialog request is completed.
GVMailDispatcher
Events
 Event Summary Defined By
  Dispatched when a mail dialog is cancelledGVMailDispatcher
  Dispatched when an email dialog failsGVMailDispatcher
  Dispatched when the user saves an emailGVMailDispatcher
  Dispatched when the user sends an emailGVMailDispatcher
Method Detail
addDialogListener()method
public function addDialogListener(listener:Function):GVMailDispatcher

Convenience method that adds an event listener for when a send mail 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:GVMailEvent) {}. You may check the value of e.type which will be either GVMailEvent.MAIL_SENT if the dialog completed successfully, GVMailEvent.MAIL_CANCELED if the dialog was canceled, GVMailEvent.MAIL_SAVED if the user saved the mail to send later, or GVMailEvent.MAIL_FAILED if the dialog was not displayed successfully.

Parameters

listener:Function — the event listener function, should take GVFacebookEvent as a parameter

Returns
GVMailDispatcher — instance of GVMailDispatcher

See also

Event Detail
MAIL_CANCELED Event
Event Object Type: com.milkmangames.nativeextensions.events.GVMailEvent

Dispatched when a mail dialog is cancelled

MAIL_FAILED Event  
Event Object Type: com.milkmangames.nativeextensions.events.GVMailEvent

Dispatched when an email dialog fails

MAIL_SAVED Event  
Event Object Type: com.milkmangames.nativeextensions.events.GVMailEvent

Dispatched when the user saves an email

MAIL_SENT Event  
Event Object Type: com.milkmangames.nativeextensions.events.GVMailEvent

Dispatched when the user sends an email