Clear Up
SharpKit Reference

EventManager Class

Registers event handlers that want to receive a normalized EventObject instead of the standard browser event and provides several useful events directly. See Ext.EventObject for more details on normalized event objects.

Namespace: Ext

Base Types

System.Object

Methods

Name Description
addListener(object, JsString, Delegate, object, object)
getId(object) Get the id of the element. If one has not been assigned, automatically assign it.
getKeyEvent() Indicates which event to use for getting key presses.
getPageX(object) Gets the x coordinate from the event
getPageXY(object) Gets the x & y coordinate from the event
getPageY(object) Gets the y coordinate from the event
getRelatedTarget(object) Gets the related target from the event.
getTarget(object) Gets the target of the event.
on() Alias for Ext.EventManager.addListener
onDocumentReady(Delegate, object, object) Adds a listener to be notified when the document is ready (before onload and before images are loaded).
onWindowResize(Delegate, object, bool) Adds a listener to be notified when the browser window is resized and provides resize event buffering (100 milliseconds), passes new viewport width and height to handlers.
onWindowUnload(Delegate, object, bool) Adds a listener to be notified when the browser window is unloaded.
pollScroll() This strategy has minimal benefits for Sencha solutions that build themselves (ie. minimal initial page markup). However, progressively-enhanced pages (with image content and/or embedded frames) will benefit the most from it. Browser timer resolution is too poor to ensure a doScroll check more than once on a page loaded with minimal assets (the readystatechange event 'complete' usually beats the doScroll timer on a 'lightly-loaded' initial document).
preventDefault(object) Prevents the browsers default handling of the event.
purgeElement(object, object) Recursively removes all previous added listeners from an element and its children. Typically you will use Ext.Element.purgeAllListeners directly on an Element in favor of calling this version.
removeAll(object) Removes all event handers from an element. Typically you will use Ext.Element.removeAllListeners directly on an Element in favor of calling this version.
removeListener(object, JsString, Delegate, object) Removes an event handler from an element. The shorthand version un is equivalent. Typically you will use Ext.Element.removeListener directly on an Element in favor of calling this version.
removeResizeListener(Delegate, object) Removes the passed window resize listener.
removeUnloadListener(Delegate, object) Removes the passed window unload listener.
stopEvent(object) Stop the event (preventDefault and stopPropagation)
stopPropagation(object) Cancels bubbling of the event.
un() Alias for Ext.EventManager.removeListener

Properties

Name Description
idleEvent Fires when a DOM event handler finishes its run, just before returning to browser control. This can be useful for performing cleanup, or upfdate tasks which need to happen only after all code in an event handler has been run, but which should not be executed in a timer due to the intervening browser reflow/repaint which would take place.
© Copyright 2005-2011 SharpKit. All rights reserved.