 						@fireEvent( 'added', @, newParent )
 					else if oldParent isnt null and newParent is null
 						@fireEvent( 'removed', @, oldParent )
-					
+
 					return result
-				
+
 				isDescendantOf: ( container ) ->
 					ancestor = @getParent()
 					while ancestor?

				Deft.event.LiveEventBus.unregister( component )
				return
		)
		
		return
)
###
Ext.define( 'Deft.event.LiveEventBus',
	alternateClassName: [ 'Deft.LiveEventBus' ]
	requires: [
		'Ext.Component'
		'Ext.ComponentManager'

		'Deft.event.LiveEventListener'
	]
	singleton: true

	constructor: ->
		@listeners = []
		return

	destroy: ->
		for listener in @listeners
			listener.destroy()
		@listeners = null
		return

	addListener: ( container, selector, eventName, fn, scope, options ) ->
		listener = Ext.create( 'Deft.event.LiveEventListener',
			container: container
			selector: selector
			eventName: eventName
