Sha256: dcc6940b44b376d0017b314b25cb5a90823ae2c19bd8f6bba0d8e8a55c0c73ba

Contents?: true

Size: 1.39 KB

Versions: 3

Compression:

Stored size: 1.39 KB

Contents

/* Copyright 2008 Theo Hultberg/Iconara */

package <%= base_package %>.controllers.event {

	import flash.events.Event;

	import <%= base_package %>.models.domain.Document;
	import <%= base_package %>.models.constant.DocumentType;

	
	/**
	 * Events of this type are used to request document-related actions such as opening, closing, 
	 * deleting, creating and updating.
	 * 
	 * All instances of this event bubble.
	 */
	public class DocumentEvent extends Event {
		
		public static const     UPDATE : String = "update";
		public static const CREATE_NEW : String = "createNew";
		public static const       OPEN : String = "open";
		public static const      CLOSE : String = "close";
		public static const     DELETE : String = "delete";
		public static const       SAVE : String = "save";
		public static const      SAVED : String = "saved";
		
		/**
		 * Events that refer to a specific document (UPDATE, OPEN, CLOSE, DELETE, SAVE and SAVED)
		 * use this property to pass that document.
		 */
		public var reference : Document;
		
		/**
		 * Events that create new documents (CREATE_NEW) use this property to specify
		 * which kind of document to create. Must be one of the constants on the DocumentType class.
		 */
		public var documentType : DocumentType;
		
		
		public function DocumentEvent( type : String, bubbles : Boolean = false, cancelable : Boolean = false ) {
			super(type, true, cancelable);
		}
		
	}
	
}

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
emergent-core-0.1.0 rails_generators/emergent_config/templates/app/flex/application/controllers/event/DocumentEvent.as
emergent-core-0.1.02 rails_generators/emergent_config/templates/app/flex/application/controllers/event/DocumentEvent.as
emergent-core-0.1.01 rails_generators/emergent_config/templates/app/flex/application/controllers/event/DocumentEvent.as