X-Git-Url: http://git.ithinksw.org/extjs.git/blobdiff_plain/ee06f37b0f6f6d94cd05a6ffae556660f7c4a2bc..c930e9176a5a85509c5b0230e2bff5c22a591432:/src/direct/Event.js?ds=sidebyside diff --git a/src/direct/Event.js b/src/direct/Event.js new file mode 100644 index 00000000..0107208c --- /dev/null +++ b/src/direct/Event.js @@ -0,0 +1,34 @@ +/*! + * Ext JS Library 3.0.0 + * Copyright(c) 2006-2009 Ext JS, LLC + * licensing@extjs.com + * http://www.extjs.com/license + */ +Ext.Direct.Event = function(config){ + Ext.apply(this, config); +} +Ext.Direct.Event.prototype = { + status: true, + getData: function(){ + return this.data; + } +}; + +Ext.Direct.RemotingEvent = Ext.extend(Ext.Direct.Event, { + type: 'rpc', + getTransaction: function(){ + return this.transaction || Ext.Direct.getTransaction(this.tid); + } +}); + +Ext.Direct.ExceptionEvent = Ext.extend(Ext.Direct.RemotingEvent, { + status: false, + type: 'exception' +}); + +Ext.Direct.eventTypes = { + 'rpc': Ext.Direct.RemotingEvent, + 'event': Ext.Direct.Event, + 'exception': Ext.Direct.ExceptionEvent +}; +