This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[EventHandler( event="com.foo.events.UserEvent.ADD_USER" )] | |
public function handleAddUserEvent( event:UserEvent ):void | |
{ | |
// do stuff | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function doURLRequestChain() : void | |
{ | |
var eventChain : EventChain = new EventChain( dispatcher ); | |
eventChain.addStep( new EventChainStep( new UserEvent( UserEvent.LOAD_USER_IMAGE ) ) ); | |
eventChain.addStep( new EventChainStep( new UserEvent( UserEvent.USER_PROCESSING_COMPLETE ) ) ); | |
eventChain.start(); | |
} | |
[EventHandler( event="UserEvent.LOAD_USER_IMAGE" )] | |
/** |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class BaseCompositeChain extends AbstractChain implements IChain | |
{ | |
public function BaseCompositeChain( mode:String = ChainType.SEQUENCE, stopOnError:Boolean = true ) | |
{ | |
super( mode, stopOnError ); | |
} | |
public function doProceed():void | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<swiz:Swiz> | |
<swiz:beanProviders> | |
<local:MyBeans /> | |
</swiz:beanProviders> | |
<swiz:loggingTargets> | |
<swiz:SwizTraceTarget id="myTraceTarget" /> | |
</swiz:loggingTargets> | |
<swiz:config> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ext.application | |
autoCreateViewport: true | |
name: "ExtCoffeeTodo" | |
Ext.onReady -> | |
#Configure IoC | |
Deft.Injector.configure | |
todoStore: "ExtCoffeeTodo.store.TodoStore" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ext.define( "ExtCoffeeTodo.view.TodoPanel", | |
extend: "Ext.grid.Panel" | |
alias: "widget.extcoffeetodo-view-todoPanel" | |
requires: [ "Ext.ux.CheckColumn", "ExtCoffeeTodo.store.TodoStore" ] | |
inject: [ "todoStore" ] | |
controller: "ExtCoffeeTodo.controller.TodoController" | |
layout: "anchor" | |
title: "ExtJS and CoffeeScript Todo List" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ext.define( "ExtCoffeeTodo.controller.TodoController", | |
extend: "Deft.mvc.ViewController" | |
requires: [ "ExtCoffeeTodo.store.TodoStore" ] | |
inject: [ "todoStore" ] | |
# Handle view events | |
control: | |
showCompletedCheckbox: | |
change: "toggleShowCompleted" | |
completeColumn: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ext.define( "ExtCoffeeTodo.store.TodoStore", | |
extend: "Ext.data.Store" | |
requires: [ "ExtCoffeeTodo.model.Todo" ] | |
# Store interacts with remote API | |
constructor: -> | |
config = | |
autoLoad: true | |
model: "ExtCoffeeTodo.model.Todo" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ext.define( "ExtCoffeeTodo.model.Todo", | |
extend: "Ext.data.Model" | |
# Models can encapsulate business logic, | |
# handle data conversion, etc. | |
fields: [ | |
name: "id" | |
, | |
name: "description" | |
type: "string" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<s:Viewport xmlns:fx="http://ns.adobe.com/mxml/2009" | |
xmlns:mx="library://ns.adobe.com/flex/mx" | |
xmlns:s="library://ns.adobe.com/flex/spark" | |
xmlns:mycontrols="todo.*"> | |
<!-- This equates to the ExtJS items array --> | |
<s:mxmlContent> | |
<s:Container> | |
<s:layout | |
type="hbox" |