a:97:{s:9:"#provides";s:4:"dojo";s:9:"#resource";s:14:"_base/event.js";s:9:"#requires";a:1:{i:0;a:2:{i:0;s:6:"common";i:1;s:18:"dojo._base.connect";}}s:18:"dojo._ieDispatcher";a:5:{s:4:"type";s:8:"Function";s:10:"parameters";a:2:{s:4:"args";a:1:{s:4:"type";s:0:"";}s:6:"sender";a:1:{s:4:"type";s:0:"";}}s:6:"source";s:467:" var ap=Array.prototype, h=dojo._ie_listener.handlers, c=args.callee, ls=c[dojo._ieListenersName], t=h[c.target]; // return value comes from original target function var r = t && t.apply(sender, args); // make local copy of listener array so it's immutable during processing var lls = [].concat(ls); // invoke listeners after target function for(var i in lls){ var f = h[lls[i]]; if(!(i in ap) && f){ f.apply(sender, args); } } return r;";s:7:"private";b:1;s:7:"summary";s:0:"";}s:21:"dojo._getIeDispatcher";a:5:{s:4:"type";s:8:"Function";s:6:"source";s:18946:"dojo.provide("dojo._base.event"); dojo.require("dojo._base.connect"); // this file courtesy of the TurboAjax Group, licensed under a Dojo CLA //>>excludeStart("webkitMobile", kwArgs.webkitMobile); (function(){ //>>excludeEnd("webkitMobile"); // DOM event listener machinery var del = (dojo._event_listener = { add: function(/*DOMNode*/node, /*String*/name, /*Function*/fp){ if(!node){return;} name = del._normalizeEventName(name); fp = del._fixCallback(name, fp); var oname = name; if( //>>excludeStart("webkitMobile", kwArgs.webkitMobile); !dojo.isIE && //>>excludeEnd("webkitMobile"); (name == "mouseenter" || name == "mouseleave") ){ var ofp = fp; //oname = name; name = (name == "mouseenter") ? "mouseover" : "mouseout"; fp = function(e){ if(dojo.isFF <= 2) { // check tagName to fix a FF2 bug with invalid nodes (hidden child DIV of INPUT) // which causes isDescendant to return false which causes // spurious, and more importantly, incorrect mouse events to fire. // TODO: remove tagName check when Firefox 2 is no longer supported try{ e.relatedTarget.tagName; }catch(e2){ return; } } if(!dojo.isDescendant(e.relatedTarget, node)){ // e.type = oname; // FIXME: doesn't take? SJM: event.type is generally immutable. return ofp.call(this, e); } } } node.addEventListener(name, fp, false); return fp; /*Handle*/ }, remove: function(/*DOMNode*/node, /*String*/event, /*Handle*/handle){ // summary: // clobbers the listener from the node // node: // DOM node to attach the event to // event: // the name of the handler to remove the function from // handle: // the handle returned from add if(node){ event = del._normalizeEventName(event); if(!dojo.isIE && (event == "mouseenter" || event == "mouseleave")){ event = (event == "mouseenter") ? "mouseover" : "mouseout"; } node.removeEventListener(event, handle, false); } }, _normalizeEventName: function(/*String*/name){ // Generally, name should be lower case, unless it is special // somehow (e.g. a Mozilla DOM event). // Remove 'on'. return name.slice(0,2) =="on" ? name.slice(2) : name; }, _fixCallback: function(/*String*/name, fp){ // By default, we only invoke _fixEvent for 'keypress' // If code is added to _fixEvent for other events, we have // to revisit this optimization. // This also applies to _fixEvent overrides for Safari and Opera // below. return name != "keypress" ? fp : function(e){ return fp.call(this, del._fixEvent(e, this)); }; }, _fixEvent: function(evt, sender){ // _fixCallback only attaches us to keypress. // Switch on evt.type anyway because we might // be called directly from dojo.fixEvent. switch(evt.type){ case "keypress": del._setKeyChar(evt); break; } return evt; }, _setKeyChar: function(evt){ evt.keyChar = evt.charCode ? String.fromCharCode(evt.charCode) : ''; evt.charOrCode = evt.keyChar || evt.keyCode; }, // For IE and Safari: some ctrl-key combinations (mostly w/punctuation) do not emit a char code in IE // we map those virtual key codes to ascii here // not valid for all (non-US) keyboards, so maybe we shouldn't bother _punctMap: { 106:42, 111:47, 186:59, 187:43, 188:44, 189:45, 190:46, 191:47, 192:96, 219:91, 220:92, 221:93, 222:39 } }); // DOM events dojo.fixEvent = function(/*Event*/evt, /*DOMNode*/sender){ // summary: // normalizes properties on the event object including event // bubbling methods, keystroke normalization, and x/y positions // evt: Event // native event object // sender: DOMNode // node to treat as "currentTarget" return del._fixEvent(evt, sender); } dojo.stopEvent = function(/*Event*/evt){ // summary: // prevents propagation and clobbers the default action of the // passed event // evt: Event // The event object. If omitted, window.event is used on IE. evt.preventDefault(); evt.stopPropagation(); // NOTE: below, this method is overridden for IE } // the default listener to use on dontFix nodes, overriden for IE var node_listener = dojo._listener; // Unify connect and event listeners dojo._connect = function(obj, event, context, method, dontFix){ // FIXME: need a more strict test var isNode = obj && (obj.nodeType||obj.attachEvent||obj.addEventListener); // choose one of three listener options: raw (connect.js), DOM event on a Node, custom event on a Node // we need the third option to provide leak prevention on broken browsers (IE) var lid = isNode ? (dontFix ? 2 : 1) : 0, l = [dojo._listener, del, node_listener][lid]; // create a listener var h = l.add(obj, event, dojo.hitch(context, method)); // formerly, the disconnect package contained "l" directly, but if client code // leaks the disconnect package (by connecting it to a node), referencing "l" // compounds the problem. // instead we return a listener id, which requires custom _disconnect below. // return disconnect package return [ obj, event, h, lid ]; } dojo._disconnect = function(obj, event, handle, listener){ ([dojo._listener, del, node_listener][listener]).remove(obj, event, handle); } // Constants // Public: client code should test // keyCode against these named constants, as the // actual codes can vary by browser. dojo.keys = { // summary: definitions for common key values BACKSPACE: 8, TAB: 9, CLEAR: 12, ENTER: 13, SHIFT: 16, CTRL: 17, ALT: 18, PAUSE: 19, CAPS_LOCK: 20, ESCAPE: 27, SPACE: 32, PAGE_UP: 33, PAGE_DOWN: 34, END: 35, HOME: 36, LEFT_ARROW: 37, UP_ARROW: 38, RIGHT_ARROW: 39, DOWN_ARROW: 40, INSERT: 45, DELETE: 46, HELP: 47, LEFT_WINDOW: 91, RIGHT_WINDOW: 92, SELECT: 93, NUMPAD_0: 96, NUMPAD_1: 97, NUMPAD_2: 98, NUMPAD_3: 99, NUMPAD_4: 100, NUMPAD_5: 101, NUMPAD_6: 102, NUMPAD_7: 103, NUMPAD_8: 104, NUMPAD_9: 105, NUMPAD_MULTIPLY: 106, NUMPAD_PLUS: 107, NUMPAD_ENTER: 108, NUMPAD_MINUS: 109, NUMPAD_PERIOD: 110, NUMPAD_DIVIDE: 111, F1: 112, F2: 113, F3: 114, F4: 115, F5: 116, F6: 117, F7: 118, F8: 119, F9: 120, F10: 121, F11: 122, F12: 123, F13: 124, F14: 125, F15: 126, NUM_LOCK: 144, SCROLL_LOCK: 145 }; //>>excludeStart("webkitMobile", kwArgs.webkitMobile); // IE event normalization if(dojo.isIE){ var _trySetKeyCode = function(e, code){ try{ // squelch errors when keyCode is read-only // (e.g. if keyCode is ctrl or shift) return (e.keyCode = code); }catch(e){ return 0; } } // by default, use the standard listener var iel = dojo._listener; var listenersName = (dojo._ieListenersName = "_" + dojo._scopeName + "_listeners"); // dispatcher tracking property if(!dojo.config._allow_leaks){ // custom listener that handles leak protection for DOM events node_listener = iel = dojo._ie_listener = { // support handler indirection: event handler functions are // referenced here. Event dispatchers hold only indices. handlers: [], // add a listener to an object add: function(/*Object*/ source, /*String*/ method, /*Function*/ listener){ source = source || dojo.global; var f = source[method]; if(!f||!f[listenersName]){ var d = dojo._getIeDispatcher(); // original target function is special d.target = f && (ieh.push(f) - 1); // dispatcher holds a list of indices into handlers table d[listenersName] = []; // redirect source to dispatcher f = source[method] = d; } return f[listenersName].push(ieh.push(listener) - 1) ; /*Handle*/ }, // remove a listener from an object remove: function(/*Object*/ source, /*String*/ method, /*Handle*/ handle){ var f = (source||dojo.global)[method], l = f && f[listenersName]; if(f && l && handle--){ delete ieh[l[handle]]; delete l[handle]; } } }; // alias used above var ieh = iel.handlers; } dojo.mixin(del, { add: function(/*DOMNode*/node, /*String*/event, /*Function*/fp){ if(!node){return;} // undefined event = del._normalizeEventName(event); if(event=="onkeypress"){ // we need to listen to onkeydown to synthesize // keypress events that otherwise won't fire // on IE var kd = node.onkeydown; if(!kd || !kd[listenersName] || !kd._stealthKeydownHandle){ var h = del.add(node, "onkeydown", del._stealthKeyDown); kd = node.onkeydown; kd._stealthKeydownHandle = h; kd._stealthKeydownRefs = 1; }else{ kd._stealthKeydownRefs++; } } return iel.add(node, event, del._fixCallback(fp)); }, remove: function(/*DOMNode*/node, /*String*/event, /*Handle*/handle){ event = del._normalizeEventName(event); iel.remove(node, event, handle); if(event=="onkeypress"){ var kd = node.onkeydown; if(--kd._stealthKeydownRefs <= 0){ iel.remove(node, "onkeydown", kd._stealthKeydownHandle); delete kd._stealthKeydownHandle; } } }, _normalizeEventName: function(/*String*/eventName){ // Generally, eventName should be lower case, unless it is // special somehow (e.g. a Mozilla event) // ensure 'on' return eventName.slice(0,2) != "on" ? "on" + eventName : eventName; }, _nop: function(){}, _fixEvent: function(/*Event*/evt, /*DOMNode*/sender){ // summary: // normalizes properties on the event object including event // bubbling methods, keystroke normalization, and x/y positions // evt: native event object // sender: node to treat as "currentTarget" if(!evt){ var w = sender && (sender.ownerDocument || sender.document || sender).parentWindow || window; evt = w.event; } if(!evt){return(evt);} evt.target = evt.srcElement; evt.currentTarget = (sender || evt.srcElement); evt.layerX = evt.offsetX; evt.layerY = evt.offsetY; // FIXME: scroll position query is duped from dojo.html to // avoid dependency on that entire module. Now that HTML is in // Base, we should convert back to something similar there. var se = evt.srcElement, doc = (se && se.ownerDocument) || document; // DO NOT replace the following to use dojo.body(), in IE, document.documentElement should be used // here rather than document.body var docBody = ((dojo.isIE < 6) || (doc["compatMode"] == "BackCompat")) ? doc.body : doc.documentElement; var offset = dojo._getIeDocumentElementOffset(); evt.pageX = evt.clientX + dojo._fixIeBiDiScrollLeft(docBody.scrollLeft || 0) - offset.x; evt.pageY = evt.clientY + (docBody.scrollTop || 0) - offset.y; if(evt.type == "mouseover"){ evt.relatedTarget = evt.fromElement; } if(evt.type == "mouseout"){ evt.relatedTarget = evt.toElement; } evt.stopPropagation = del._stopPropagation; evt.preventDefault = del._preventDefault; return del._fixKeys(evt); }, _fixKeys: function(evt){ switch(evt.type){ case "keypress": var c = ("charCode" in evt ? evt.charCode : evt.keyCode); if (c==10){ // CTRL-ENTER is CTRL-ASCII(10) on IE, but CTRL-ENTER on Mozilla c=0; evt.keyCode = 13; }else if(c==13||c==27){ c=0; // Mozilla considers ENTER and ESC non-printable }else if(c==3){ c=99; // Mozilla maps CTRL-BREAK to CTRL-c } // Mozilla sets keyCode to 0 when there is a charCode // but that stops the event on IE. evt.charCode = c; del._setKeyChar(evt); break; } return evt; }, _stealthKeyDown: function(evt){ // IE doesn't fire keypress for most non-printable characters. // other browsers do, we simulate it here. var kp = evt.currentTarget.onkeypress; // only works if kp exists and is a dispatcher if(!kp || !kp[listenersName]){ return; } // munge key/charCode var k=evt.keyCode; // These are Windows Virtual Key Codes // http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/UserInput/VirtualKeyCodes.asp var unprintable = k!=13 && k!=32 && k!=27 && (k<48||k>90) && (k<96||k>111) && (k<186||k>192) && (k<219||k>222); // synthesize keypress for most unprintables and CTRL-keys if(unprintable||evt.ctrlKey){ var c = unprintable ? 0 : k; if(evt.ctrlKey){ if(k==3 || k==13){ return; // IE will post CTRL-BREAK, CTRL-ENTER as keypress natively }else if(c>95 && c<106){ c -= 48; // map CTRL-[numpad 0-9] to ASCII }else if((!evt.shiftKey)&&(c>=65&&c<=90)){ c += 32; // map CTRL-[A-Z] to lowercase }else{ c = del._punctMap[c] || c; // map other problematic CTRL combinations to ASCII } } // simulate a keypress event var faux = del._synthesizeEvent(evt, {type: 'keypress', faux: true, charCode: c}); kp.call(evt.currentTarget, faux); evt.cancelBubble = faux.cancelBubble; evt.returnValue = faux.returnValue; _trySetKeyCode(evt, faux.keyCode); } }, // Called in Event scope _stopPropagation: function(){ this.cancelBubble = true; }, _preventDefault: function(){ // Setting keyCode to 0 is the only way to prevent certain keypresses (namely // ctrl-combinations that correspond to menu accelerator keys). // Otoh, it prevents upstream listeners from getting this information // Try to split the difference here by clobbering keyCode only for ctrl // combinations. If you still need to access the key upstream, bubbledKeyCode is // provided as a workaround. this.bubbledKeyCode = this.keyCode; if(this.ctrlKey){_trySetKeyCode(this, 0);} this.returnValue = false; } }); // override stopEvent for IE dojo.stopEvent = function(evt){ evt = evt || window.event; del._stopPropagation.call(evt); del._preventDefault.call(evt); } } //>>excludeEnd("webkitMobile"); del._synthesizeEvent = function(evt, props){ var faux = dojo.mixin({}, evt, props); del._setKeyChar(faux); // FIXME: would prefer to use dojo.hitch: dojo.hitch(evt, evt.preventDefault); // but it throws an error when preventDefault is invoked on Safari // does Event.preventDefault not support "apply" on Safari? faux.preventDefault = function(){ evt.preventDefault(); }; faux.stopPropagation = function(){ evt.stopPropagation(); }; return faux; } //>>excludeStart("webkitMobile", kwArgs.webkitMobile); // Opera event normalization if(dojo.isOpera){ dojo.mixin(del, { _fixEvent: function(evt, sender){ switch(evt.type){ case "keypress": var c = evt.which; if(c==3){ c=99; // Mozilla maps CTRL-BREAK to CTRL-c } // can't trap some keys at all, like INSERT and DELETE // there is no differentiating info between DELETE and ".", or INSERT and "-" c = c<41 && !evt.shiftKey ? 0 : c; if(evt.ctrlKey && !evt.shiftKey && c>=65 && c<=90){ // lowercase CTRL-[A-Z] keys c += 32; } return del._synthesizeEvent(evt, { charCode: c }); } return evt; } }); } //>>excludeEnd("webkitMobile"); //>>excludeStart("webkitMobile", kwArgs.webkitMobile); // Webkit event normalization if(dojo.isWebKit){ //>>excludeEnd("webkitMobile"); del._add = del.add; del._remove = del.remove; dojo.mixin(del, { add: function(/*DOMNode*/node, /*String*/event, /*Function*/fp){ if(!node){return;} // undefined var handle = del._add(node, event, fp); if(del._normalizeEventName(event) == "keypress"){ // we need to listen to onkeydown to synthesize // keypress events that otherwise won't fire // in Safari 3.1+: https://lists.webkit.org/pipermail/webkit-dev/2007-December/002992.html handle._stealthKeyDownHandle = del._add(node, "keydown", function(evt){ //A variation on the IE _stealthKeydown function //Synthesize an onkeypress event, but only for unprintable characters. var k=evt.keyCode; // These are Windows Virtual Key Codes // http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/UserInput/VirtualKeyCodes.asp var unprintable = k!=13 && k!=32 && k!=27 && (k<48 || k>90) && (k<96 || k>111) && (k<186 || k>192) && (k<219 || k>222); // synthesize keypress for most unprintables and CTRL-keys if(unprintable || evt.ctrlKey){ var c = unprintable ? 0 : k; if(evt.ctrlKey){ if(k==3 || k==13){ return; // IE will post CTRL-BREAK, CTRL-ENTER as keypress natively }else if(c>95 && c<106){ c -= 48; // map CTRL-[numpad 0-9] to ASCII }else if(!evt.shiftKey && c>=65 && c<=90){ c += 32; // map CTRL-[A-Z] to lowercase }else{ c = del._punctMap[c] || c; // map other problematic CTRL combinations to ASCII } } // simulate a keypress event var faux = del._synthesizeEvent(evt, {type: 'keypress', faux: true, charCode: c}); fp.call(evt.currentTarget, faux); } }); } return handle; /*Handle*/ }, remove: function(/*DOMNode*/node, /*String*/event, /*Handle*/handle){ if(node){ if(handle._stealthKeyDownHandle){ del._remove(node, "keydown", handle._stealthKeyDownHandle); } del._remove(node, event, handle); } }, _fixEvent: function(evt, sender){ switch(evt.type){ case "keypress": if(evt.faux){ return evt; } var c = evt.charCode; c = c>=32 ? c : 0; return del._synthesizeEvent(evt, {charCode: c, faux: true}); } return evt; } }); //>>excludeStart("webkitMobile", kwArgs.webkitMobile); } //>>excludeEnd("webkitMobile"); //>>excludeStart("webkitMobile", kwArgs.webkitMobile); })(); //>>excludeEnd("webkitMobile"); //>>excludeStart("webkitMobile", kwArgs.webkitMobile); if(dojo.isIE){ // keep this out of the closure // closing over 'iel' or 'ieh' b0rks leak prevention // ls[i] is an index into the master handler array dojo._ieDispatcher = function(args, sender){ var ap=Array.prototype, h=dojo._ie_listener.handlers, c=args.callee, ls=c[dojo._ieListenersName], t=h[c.target]; // return value comes from original target function var r = t && t.apply(sender, args); // make local copy of listener array so it's immutable during processing var lls = [].concat(ls); // invoke listeners after target function for(var i in lls){ var f = h[lls[i]]; if(!(i in ap) && f){ f.apply(sender, args); } } return r; } dojo._getIeDispatcher = function(){ // ensure the returned function closes over nothing ("new Function" apparently doesn't close) return new Function(dojo._scopeName + "._ieDispatcher(arguments, this)"); // function";s:7:"returns";s:82:"Handle|undefined|IE will post CTRL-BREAK, CTRL-ENTER as keypress natively|function";s:7:"private";b:1;s:7:"summary";s:0:"";}s:33:"dojo._event_listener._fixCallback";a:7:{s:4:"type";s:8:"Function";s:10:"parameters";a:2:{s:2:"fp";a:1:{s:4:"type";s:0:"";}s:4:"name";a:1:{s:4:"type";s:6:"String";}}s:6:"source";s:2643:"dojo.provide("dojo._base.event"); dojo.require("dojo._base.connect"); // this file courtesy of the TurboAjax Group, licensed under a Dojo CLA //>>excludeStart("webkitMobile", kwArgs.webkitMobile); (function(){ //>>excludeEnd("webkitMobile"); // DOM event listener machinery var del = (dojo._event_listener = { add: function(/*DOMNode*/node, /*String*/name, /*Function*/fp){ if(!node){return;} name = del._normalizeEventName(name); fp = del._fixCallback(name, fp); var oname = name; if( //>>excludeStart("webkitMobile", kwArgs.webkitMobile); !dojo.isIE && //>>excludeEnd("webkitMobile"); (name == "mouseenter" || name == "mouseleave") ){ var ofp = fp; //oname = name; name = (name == "mouseenter") ? "mouseover" : "mouseout"; fp = function(e){ if(dojo.isFF <= 2) { // check tagName to fix a FF2 bug with invalid nodes (hidden child DIV of INPUT) // which causes isDescendant to return false which causes // spurious, and more importantly, incorrect mouse events to fire. // TODO: remove tagName check when Firefox 2 is no longer supported try{ e.relatedTarget.tagName; }catch(e2){ return; } } if(!dojo.isDescendant(e.relatedTarget, node)){ // e.type = oname; // FIXME: doesn't take? SJM: event.type is generally immutable. return ofp.call(this, e); } } } node.addEventListener(name, fp, false); return fp; /*Handle*/ }, remove: function(/*DOMNode*/node, /*String*/event, /*Handle*/handle){ // summary: // clobbers the listener from the node // node: // DOM node to attach the event to // event: // the name of the handler to remove the function from // handle: // the handle returned from add if(node){ event = del._normalizeEventName(event); if(!dojo.isIE && (event == "mouseenter" || event == "mouseleave")){ event = (event == "mouseenter") ? "mouseover" : "mouseout"; } node.removeEventListener(event, handle, false); } }, _normalizeEventName: function(/*String*/name){ // Generally, name should be lower case, unless it is special // somehow (e.g. a Mozilla DOM event). // Remove 'on'. return name.slice(0,2) =="on" ? name.slice(2) : name; }, _fixCallback: function(/*String*/name, fp){ // By default, we only invoke _fixEvent for 'keypress' // If code is added to _fixEvent for other events, we have // to revisit this optimization. // This also applies to _fixEvent overrides for Safari and Opera // below. return name != "keypress" ? fp : function(e){ return fp.call(this, del._fixEvent(e, this)); };";s:7:"returns";s:6:"Handle";s:7:"private";b:1;s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:9:"dojo.keys";a:2:{s:4:"type";s:6:"Object";s:7:"summary";s:33:"definitions for common key values";}s:20:"del._synthesizeEvent";a:2:{s:7:"private";b:1;s:7:"summary";s:0:"";}s:8:"del._add";a:2:{s:7:"private";b:1;s:7:"summary";s:0:"";}s:11:"del._remove";a:2:{s:7:"private";b:1;s:7:"summary";s:0:"";}s:13:"dojo.fixEvent";a:4:{s:4:"type";s:8:"Function";s:10:"parameters";a:2:{s:3:"evt";a:2:{s:4:"type";s:5:"Event";s:7:"summary";s:19:"native event object";}s:6:"sender";a:2:{s:4:"type";s:7:"DOMNode";s:7:"summary";s:42:"node to treat as "currentTarget"";}}s:6:"source";s:36:" return del._fixEvent(evt, sender);";s:7:"summary";s:118:"normalizes properties on the event object including event bubbling methods, keystroke normalization, and x/y positions";}s:14:"dojo.stopEvent";a:4:{s:4:"type";s:8:"Function";s:10:"parameters";a:1:{s:3:"evt";a:2:{s:4:"type";s:5:"Event";s:7:"summary";s:57:"The event object. If omitted, window.event is used on IE.";}}s:6:"source";s:98:" evt = evt || window.event; del._stopPropagation.call(evt); del._preventDefault.call(evt);";s:7:"summary";s:72:"prevents propagation and clobbers the default action of the passed event";}s:13:"dojo._connect";a:6:{s:4:"type";s:8:"Function";s:10:"parameters";a:5:{s:3:"obj";a:1:{s:4:"type";s:0:"";}s:5:"event";a:1:{s:4:"type";s:0:"";}s:7:"context";a:1:{s:4:"type";s:0:"";}s:6:"method";a:1:{s:4:"type";s:0:"";}s:7:"dontFix";a:1:{s:4:"type";s:0:"";}}s:6:"source";s:5204:"dojo.provide("dojo._base.event"); dojo.require("dojo._base.connect"); // this file courtesy of the TurboAjax Group, licensed under a Dojo CLA //>>excludeStart("webkitMobile", kwArgs.webkitMobile); (function(){ //>>excludeEnd("webkitMobile"); // DOM event listener machinery var del = (dojo._event_listener = { add: function(/*DOMNode*/node, /*String*/name, /*Function*/fp){ if(!node){return;} name = del._normalizeEventName(name); fp = del._fixCallback(name, fp); var oname = name; if( //>>excludeStart("webkitMobile", kwArgs.webkitMobile); !dojo.isIE && //>>excludeEnd("webkitMobile"); (name == "mouseenter" || name == "mouseleave") ){ var ofp = fp; //oname = name; name = (name == "mouseenter") ? "mouseover" : "mouseout"; fp = function(e){ if(dojo.isFF <= 2) { // check tagName to fix a FF2 bug with invalid nodes (hidden child DIV of INPUT) // which causes isDescendant to return false which causes // spurious, and more importantly, incorrect mouse events to fire. // TODO: remove tagName check when Firefox 2 is no longer supported try{ e.relatedTarget.tagName; }catch(e2){ return; } } if(!dojo.isDescendant(e.relatedTarget, node)){ // e.type = oname; // FIXME: doesn't take? SJM: event.type is generally immutable. return ofp.call(this, e); } } } node.addEventListener(name, fp, false); return fp; /*Handle*/ }, remove: function(/*DOMNode*/node, /*String*/event, /*Handle*/handle){ // summary: // clobbers the listener from the node // node: // DOM node to attach the event to // event: // the name of the handler to remove the function from // handle: // the handle returned from add if(node){ event = del._normalizeEventName(event); if(!dojo.isIE && (event == "mouseenter" || event == "mouseleave")){ event = (event == "mouseenter") ? "mouseover" : "mouseout"; } node.removeEventListener(event, handle, false); } }, _normalizeEventName: function(/*String*/name){ // Generally, name should be lower case, unless it is special // somehow (e.g. a Mozilla DOM event). // Remove 'on'. return name.slice(0,2) =="on" ? name.slice(2) : name; }, _fixCallback: function(/*String*/name, fp){ // By default, we only invoke _fixEvent for 'keypress' // If code is added to _fixEvent for other events, we have // to revisit this optimization. // This also applies to _fixEvent overrides for Safari and Opera // below. return name != "keypress" ? fp : function(e){ return fp.call(this, del._fixEvent(e, this)); }; }, _fixEvent: function(evt, sender){ // _fixCallback only attaches us to keypress. // Switch on evt.type anyway because we might // be called directly from dojo.fixEvent. switch(evt.type){ case "keypress": del._setKeyChar(evt); break; } return evt; }, _setKeyChar: function(evt){ evt.keyChar = evt.charCode ? String.fromCharCode(evt.charCode) : ''; evt.charOrCode = evt.keyChar || evt.keyCode; }, // For IE and Safari: some ctrl-key combinations (mostly w/punctuation) do not emit a char code in IE // we map those virtual key codes to ascii here // not valid for all (non-US) keyboards, so maybe we shouldn't bother _punctMap: { 106:42, 111:47, 186:59, 187:43, 188:44, 189:45, 190:46, 191:47, 192:96, 219:91, 220:92, 221:93, 222:39 } }); // DOM events dojo.fixEvent = function(/*Event*/evt, /*DOMNode*/sender){ // summary: // normalizes properties on the event object including event // bubbling methods, keystroke normalization, and x/y positions // evt: Event // native event object // sender: DOMNode // node to treat as "currentTarget" return del._fixEvent(evt, sender); } dojo.stopEvent = function(/*Event*/evt){ // summary: // prevents propagation and clobbers the default action of the // passed event // evt: Event // The event object. If omitted, window.event is used on IE. evt.preventDefault(); evt.stopPropagation(); // NOTE: below, this method is overridden for IE } // the default listener to use on dontFix nodes, overriden for IE var node_listener = dojo._listener; // Unify connect and event listeners dojo._connect = function(obj, event, context, method, dontFix){ // FIXME: need a more strict test var isNode = obj && (obj.nodeType||obj.attachEvent||obj.addEventListener); // choose one of three listener options: raw (connect.js), DOM event on a Node, custom event on a Node // we need the third option to provide leak prevention on broken browsers (IE) var lid = isNode ? (dontFix ? 2 : 1) : 0, l = [dojo._listener, del, node_listener][lid]; // create a listener var h = l.add(obj, event, dojo.hitch(context, method)); // formerly, the disconnect package contained "l" directly, but if client code // leaks the disconnect package (by connecting it to a node), referencing "l" // compounds the problem. // instead we return a listener id, which requires custom _disconnect below. // return disconnect package return [ obj, event, h, lid ];";s:7:"returns";s:6:"Handle";s:7:"private";b:1;s:7:"summary";s:0:"";}s:16:"dojo._disconnect";a:5:{s:4:"type";s:8:"Function";s:10:"parameters";a:4:{s:3:"obj";a:1:{s:4:"type";s:0:"";}s:5:"event";a:1:{s:4:"type";s:0:"";}s:6:"handle";a:1:{s:4:"type";s:0:"";}s:8:"listener";a:1:{s:4:"type";s:0:"";}}s:6:"source";s:78:" ([dojo._listener, del, node_listener][listener]).remove(obj, event, handle);";s:7:"private";b:1;s:7:"summary";s:0:"";}s:24:"dojo._event_listener.add";a:6:{s:4:"type";s:8:"Function";s:10:"parameters";a:3:{s:4:"node";a:1:{s:4:"type";s:7:"DOMNode";}s:4:"name";a:1:{s:4:"type";s:6:"String";}s:2:"fp";a:1:{s:4:"type";s:8:"Function";}}s:6:"source";s:1071:" if(!node){return;} name = del._normalizeEventName(name); fp = del._fixCallback(name, fp); var oname = name; if( //>>excludeStart("webkitMobile", kwArgs.webkitMobile); !dojo.isIE && //>>excludeEnd("webkitMobile"); (name == "mouseenter" || name == "mouseleave") ){ var ofp = fp; //oname = name; name = (name == "mouseenter") ? "mouseover" : "mouseout"; fp = function(e){ if(dojo.isFF <= 2) { // check tagName to fix a FF2 bug with invalid nodes (hidden child DIV of INPUT) // which causes isDescendant to return false which causes // spurious, and more importantly, incorrect mouse events to fire. // TODO: remove tagName check when Firefox 2 is no longer supported try{ e.relatedTarget.tagName; }catch(e2){ return; } } if(!dojo.isDescendant(e.relatedTarget, node)){ // e.type = oname; // FIXME: doesn't take? SJM: event.type is generally immutable. return ofp.call(this, e); } } } node.addEventListener(name, fp, false); return fp; /*Handle*/";s:7:"returns";s:6:"Handle";s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:27:"dojo._event_listener.remove";a:5:{s:4:"type";s:8:"Function";s:10:"parameters";a:3:{s:4:"node";a:2:{s:4:"type";s:7:"DOMNode";s:7:"summary";s:31:"DOM node to attach the event to";}s:5:"event";a:2:{s:4:"type";s:6:"String";s:7:"summary";s:51:"the name of the handler to remove the function from";}s:6:"handle";a:2:{s:4:"type";s:6:"Handle";s:7:"summary";s:28:"the handle returned from add";}}s:6:"source";s:258:" if(node){ event = del._normalizeEventName(event); if(!dojo.isIE && (event == "mouseenter" || event == "mouseleave")){ event = (event == "mouseenter") ? "mouseover" : "mouseout"; } node.removeEventListener(event, handle, false); }";s:7:"summary";s:35:"clobbers the listener from the node";s:14:"private_parent";b:1;}s:40:"dojo._event_listener._normalizeEventName";a:7:{s:4:"type";s:8:"Function";s:10:"parameters";a:1:{s:4:"name";a:1:{s:4:"type";s:6:"String";}}s:6:"source";s:2257:"dojo.provide("dojo._base.event"); dojo.require("dojo._base.connect"); // this file courtesy of the TurboAjax Group, licensed under a Dojo CLA //>>excludeStart("webkitMobile", kwArgs.webkitMobile); (function(){ //>>excludeEnd("webkitMobile"); // DOM event listener machinery var del = (dojo._event_listener = { add: function(/*DOMNode*/node, /*String*/name, /*Function*/fp){ if(!node){return;} name = del._normalizeEventName(name); fp = del._fixCallback(name, fp); var oname = name; if( //>>excludeStart("webkitMobile", kwArgs.webkitMobile); !dojo.isIE && //>>excludeEnd("webkitMobile"); (name == "mouseenter" || name == "mouseleave") ){ var ofp = fp; //oname = name; name = (name == "mouseenter") ? "mouseover" : "mouseout"; fp = function(e){ if(dojo.isFF <= 2) { // check tagName to fix a FF2 bug with invalid nodes (hidden child DIV of INPUT) // which causes isDescendant to return false which causes // spurious, and more importantly, incorrect mouse events to fire. // TODO: remove tagName check when Firefox 2 is no longer supported try{ e.relatedTarget.tagName; }catch(e2){ return; } } if(!dojo.isDescendant(e.relatedTarget, node)){ // e.type = oname; // FIXME: doesn't take? SJM: event.type is generally immutable. return ofp.call(this, e); } } } node.addEventListener(name, fp, false); return fp; /*Handle*/ }, remove: function(/*DOMNode*/node, /*String*/event, /*Handle*/handle){ // summary: // clobbers the listener from the node // node: // DOM node to attach the event to // event: // the name of the handler to remove the function from // handle: // the handle returned from add if(node){ event = del._normalizeEventName(event); if(!dojo.isIE && (event == "mouseenter" || event == "mouseleave")){ event = (event == "mouseenter") ? "mouseover" : "mouseout"; } node.removeEventListener(event, handle, false); } }, _normalizeEventName: function(/*String*/name){ // Generally, name should be lower case, unless it is special // somehow (e.g. a Mozilla DOM event). // Remove 'on'. return name.slice(0,2) =="on" ? name.slice(2) : name;";s:7:"returns";s:6:"Handle";s:7:"private";b:1;s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:30:"dojo._event_listener._fixEvent";a:7:{s:4:"type";s:8:"Function";s:10:"parameters";a:2:{s:3:"evt";a:1:{s:4:"type";s:0:"";}s:6:"sender";a:1:{s:4:"type";s:0:"";}}s:6:"source";s:2929:"dojo.provide("dojo._base.event"); dojo.require("dojo._base.connect"); // this file courtesy of the TurboAjax Group, licensed under a Dojo CLA //>>excludeStart("webkitMobile", kwArgs.webkitMobile); (function(){ //>>excludeEnd("webkitMobile"); // DOM event listener machinery var del = (dojo._event_listener = { add: function(/*DOMNode*/node, /*String*/name, /*Function*/fp){ if(!node){return;} name = del._normalizeEventName(name); fp = del._fixCallback(name, fp); var oname = name; if( //>>excludeStart("webkitMobile", kwArgs.webkitMobile); !dojo.isIE && //>>excludeEnd("webkitMobile"); (name == "mouseenter" || name == "mouseleave") ){ var ofp = fp; //oname = name; name = (name == "mouseenter") ? "mouseover" : "mouseout"; fp = function(e){ if(dojo.isFF <= 2) { // check tagName to fix a FF2 bug with invalid nodes (hidden child DIV of INPUT) // which causes isDescendant to return false which causes // spurious, and more importantly, incorrect mouse events to fire. // TODO: remove tagName check when Firefox 2 is no longer supported try{ e.relatedTarget.tagName; }catch(e2){ return; } } if(!dojo.isDescendant(e.relatedTarget, node)){ // e.type = oname; // FIXME: doesn't take? SJM: event.type is generally immutable. return ofp.call(this, e); } } } node.addEventListener(name, fp, false); return fp; /*Handle*/ }, remove: function(/*DOMNode*/node, /*String*/event, /*Handle*/handle){ // summary: // clobbers the listener from the node // node: // DOM node to attach the event to // event: // the name of the handler to remove the function from // handle: // the handle returned from add if(node){ event = del._normalizeEventName(event); if(!dojo.isIE && (event == "mouseenter" || event == "mouseleave")){ event = (event == "mouseenter") ? "mouseover" : "mouseout"; } node.removeEventListener(event, handle, false); } }, _normalizeEventName: function(/*String*/name){ // Generally, name should be lower case, unless it is special // somehow (e.g. a Mozilla DOM event). // Remove 'on'. return name.slice(0,2) =="on" ? name.slice(2) : name; }, _fixCallback: function(/*String*/name, fp){ // By default, we only invoke _fixEvent for 'keypress' // If code is added to _fixEvent for other events, we have // to revisit this optimization. // This also applies to _fixEvent overrides for Safari and Opera // below. return name != "keypress" ? fp : function(e){ return fp.call(this, del._fixEvent(e, this)); }; }, _fixEvent: function(evt, sender){ // _fixCallback only attaches us to keypress. // Switch on evt.type anyway because we might // be called directly from dojo.fixEvent. switch(evt.type){ case "keypress": del._setKeyChar(evt); break; } return evt;";s:7:"returns";s:6:"Handle";s:7:"private";b:1;s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:32:"dojo._event_listener._setKeyChar";a:6:{s:4:"type";s:8:"Function";s:10:"parameters";a:1:{s:3:"evt";a:1:{s:4:"type";s:0:"";}}s:6:"source";s:119:" evt.keyChar = evt.charCode ? String.fromCharCode(evt.charCode) : ''; evt.charOrCode = evt.keyChar || evt.keyCode;";s:7:"private";b:1;s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.106";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.111";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.186";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.187";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.188";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.189";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.190";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.191";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.192";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.219";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.220";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.221";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:34:"dojo._event_listener._punctMap.222";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:30:"dojo._event_listener._punctMap";a:4:{s:4:"type";s:6:"Object";s:7:"private";b:1;s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:20:"dojo._event_listener";a:3:{s:4:"type";s:6:"Object";s:7:"private";b:1;s:7:"summary";s:0:"";}s:19:"dojo.keys.BACKSPACE";a:1:{s:7:"summary";s:0:"";}s:13:"dojo.keys.TAB";a:1:{s:7:"summary";s:0:"";}s:15:"dojo.keys.CLEAR";a:1:{s:7:"summary";s:0:"";}s:15:"dojo.keys.ENTER";a:1:{s:7:"summary";s:0:"";}s:15:"dojo.keys.SHIFT";a:1:{s:7:"summary";s:0:"";}s:14:"dojo.keys.CTRL";a:1:{s:7:"summary";s:0:"";}s:13:"dojo.keys.ALT";a:1:{s:7:"summary";s:0:"";}s:15:"dojo.keys.PAUSE";a:1:{s:7:"summary";s:0:"";}s:19:"dojo.keys.CAPS_LOCK";a:1:{s:7:"summary";s:0:"";}s:16:"dojo.keys.ESCAPE";a:1:{s:7:"summary";s:0:"";}s:15:"dojo.keys.SPACE";a:1:{s:7:"summary";s:0:"";}s:17:"dojo.keys.PAGE_UP";a:1:{s:7:"summary";s:0:"";}s:19:"dojo.keys.PAGE_DOWN";a:1:{s:7:"summary";s:0:"";}s:13:"dojo.keys.END";a:1:{s:7:"summary";s:0:"";}s:14:"dojo.keys.HOME";a:1:{s:7:"summary";s:0:"";}s:20:"dojo.keys.LEFT_ARROW";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.UP_ARROW";a:1:{s:7:"summary";s:0:"";}s:21:"dojo.keys.RIGHT_ARROW";a:1:{s:7:"summary";s:0:"";}s:20:"dojo.keys.DOWN_ARROW";a:1:{s:7:"summary";s:0:"";}s:16:"dojo.keys.INSERT";a:1:{s:7:"summary";s:0:"";}s:16:"dojo.keys.DELETE";a:1:{s:7:"summary";s:0:"";}s:14:"dojo.keys.HELP";a:1:{s:7:"summary";s:0:"";}s:21:"dojo.keys.LEFT_WINDOW";a:1:{s:7:"summary";s:0:"";}s:22:"dojo.keys.RIGHT_WINDOW";a:1:{s:7:"summary";s:0:"";}s:16:"dojo.keys.SELECT";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_0";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_1";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_2";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_3";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_4";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_5";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_6";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_7";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_8";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUMPAD_9";a:1:{s:7:"summary";s:0:"";}s:25:"dojo.keys.NUMPAD_MULTIPLY";a:1:{s:7:"summary";s:0:"";}s:21:"dojo.keys.NUMPAD_PLUS";a:1:{s:7:"summary";s:0:"";}s:22:"dojo.keys.NUMPAD_ENTER";a:1:{s:7:"summary";s:0:"";}s:22:"dojo.keys.NUMPAD_MINUS";a:1:{s:7:"summary";s:0:"";}s:23:"dojo.keys.NUMPAD_PERIOD";a:1:{s:7:"summary";s:0:"";}s:23:"dojo.keys.NUMPAD_DIVIDE";a:1:{s:7:"summary";s:0:"";}s:12:"dojo.keys.F1";a:1:{s:7:"summary";s:0:"";}s:12:"dojo.keys.F2";a:1:{s:7:"summary";s:0:"";}s:12:"dojo.keys.F3";a:1:{s:7:"summary";s:0:"";}s:12:"dojo.keys.F4";a:1:{s:7:"summary";s:0:"";}s:12:"dojo.keys.F5";a:1:{s:7:"summary";s:0:"";}s:12:"dojo.keys.F6";a:1:{s:7:"summary";s:0:"";}s:12:"dojo.keys.F7";a:1:{s:7:"summary";s:0:"";}s:12:"dojo.keys.F8";a:1:{s:7:"summary";s:0:"";}s:12:"dojo.keys.F9";a:1:{s:7:"summary";s:0:"";}s:13:"dojo.keys.F10";a:1:{s:7:"summary";s:0:"";}s:13:"dojo.keys.F11";a:1:{s:7:"summary";s:0:"";}s:13:"dojo.keys.F12";a:1:{s:7:"summary";s:0:"";}s:13:"dojo.keys.F13";a:1:{s:7:"summary";s:0:"";}s:13:"dojo.keys.F14";a:1:{s:7:"summary";s:0:"";}s:13:"dojo.keys.F15";a:1:{s:7:"summary";s:0:"";}s:18:"dojo.keys.NUM_LOCK";a:1:{s:7:"summary";s:0:"";}s:21:"dojo.keys.SCROLL_LOCK";a:1:{s:7:"summary";s:0:"";}s:26:"dojo._ie_listener.handlers";a:2:{s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:21:"dojo._ie_listener.add";a:6:{s:4:"type";s:8:"Function";s:10:"parameters";a:3:{s:6:"source";a:1:{s:4:"type";s:6:"Object";}s:6:"method";a:1:{s:4:"type";s:6:"String";}s:8:"listener";a:1:{s:4:"type";s:8:"Function";}}s:6:"source";s:462:" source = source || dojo.global; var f = source[method]; if(!f||!f[listenersName]){ var d = dojo._getIeDispatcher(); // original target function is special d.target = f && (ieh.push(f) - 1); // dispatcher holds a list of indices into handlers table d[listenersName] = []; // redirect source to dispatcher f = source[method] = d; } return f[listenersName].push(ieh.push(listener) - 1) ; /*Handle*/";s:7:"returns";s:6:"Handle";s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:24:"dojo._ie_listener.remove";a:5:{s:4:"type";s:8:"Function";s:10:"parameters";a:3:{s:6:"source";a:1:{s:4:"type";s:6:"Object";}s:6:"method";a:1:{s:4:"type";s:6:"String";}s:6:"handle";a:1:{s:4:"type";s:6:"Handle";}}s:6:"source";s:159:" var f = (source||dojo.global)[method], l = f && f[listenersName]; if(f && l && handle--){ delete ieh[l[handle]]; delete l[handle]; }";s:14:"private_parent";b:1;s:7:"summary";s:0:"";}s:17:"dojo._ie_listener";a:3:{s:4:"type";s:6:"Object";s:7:"private";b:1;s:7:"summary";s:0:"";}s:4:"dojo";a:2:{s:4:"type";s:6:"Object";s:7:"summary";s:0:"";}}