JavaScript Page /Scripts/jquery-1.4.1.js (VB.NET)
1: /*
2: * This file has been commented to support Visual Studio Intellisense.
3: * You should not use this file at runtime inside the browser--it is only
4: * intended to be used only for design-time IntelliSense. Please use the
5: * standard jQuery library for all production use.
6: *
7: * Comment version: 1.4.1a
8: */
9:
10: /*!
11: * jQuery JavaScript Library v1.4.1
12: * http://jquery.com/
13: *
14: * Distributed in whole under the terms of the MIT
15: *
16: * Copyright 2010, John Resig
17: *
18: * Permission is hereby granted, free of charge, to any person obtaining
19: * a copy of this software and associated documentation files (the
20: * "Software"), to deal in the Software without restriction, including
21: * without limitation the rights to use, copy, modify, merge, publish,
22: * distribute, sublicense, and/or sell copies of the Software, and to
23: * permit persons to whom the Software is furnished to do so, subject to
24: * the following conditions:
25: *
26: * The above copyright notice and this permission notice shall be
27: * included in all copies or substantial portions of the Software.
28: *
29: * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
30: * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
31: * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
32: * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
33: * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
34: * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
35: * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
36: *
37: * Includes Sizzle.js
38: * http://sizzlejs.com/
39: * Copyright 2010, The Dojo Foundation
40: * Released under the MIT, BSD, and GPL Licenses.
41: *
42: * Date: Mon Jan 25 19:43:33 2010 -0500
43: */
44:
45: (function( window, undefined ) {
46:
47: // Define a local copy of jQuery
48: var jQuery = function( selector, context ) {
49:         ///    <summary>
50:         ///        1: $(expression, context) - This function accepts a string containing a CSS selector which is then used to match a set of elements.
51:         ///        2: $(html) - Create DOM elements on-the-fly from the provided String of raw HTML.
52:         ///        3: $(elements) - Wrap jQuery functionality around a single or multiple DOM Element(s).
53:         ///        4: $(callback) - A shorthand for $(document).ready().
54:         ///        5: $() - As of jQuery 1.4, if you pass no arguments in to the jQuery() method, an empty jQuery set will be returned.
55:         ///    </summary>
56:         ///    <param name="selector" type="String">
57:         ///        1: expression - An expression to search with.
58:         ///        2: html - A string of HTML to create on the fly.
59:         ///        3: elements - DOM element(s) to be encapsulated by a jQuery object.
60:         ///        4: callback - The function to execute when the DOM is ready.
61:         ///    </param>
62:         ///    <param name="context" type="jQuery">
63:         ///        1: context - A DOM Element, Document or jQuery to use as context.
64:         ///    </param>
65:         ///    <returns type="jQuery" />
66:
67:         // The jQuery object is actually just the init constructor 'enhanced'
68:         return new jQuery.fn.init( selector, context );
69:     },
70:
71:     // Map over jQuery in case of overwrite
72:     _jQuery = window.jQuery,
73:
74:     // Map over the $ in case of overwrite
75:     _$ = window.$,
76:
77:     // Use the correct document accordingly with window argument (sandbox)
78:     document = window.document,
79:
80:     // A central reference to the root jQuery(document)
81:     rootjQuery,
82:
83:     // A simple way to check for HTML strings or ID strings
84:     // (both of which we optimize for)
85:     quickExpr = /^[^<]*(<[\w\W]+>)[^>]*$|^#([\w-]+)$/,
86:
87:     // Is it a simple selector
88:     isSimple = /^.[^:#\[\.,]*$/,
89:
90:     // Check if a string has a non-whitespace character in it
91:     rnotwhite = /\S/,
92:
93:     // Used for trimming whitespace
94:     rtrim = /^(\s|\u00A0)+|(\s|\u00A0)+$/g,
95:
96:     // Match a standalone tag
97:     rsingleTag = /^<(\w+)\s*\/?>(?:<\/\1>)?$/,
98:
99:     // Keep a UserAgent string for use with jQuery.browser
100:     userAgent = navigator.userAgent,
101:
102:     // For matching the engine and version of the browser
103:     browserMatch,
104:     
105:     // Has the ready events already been bound?
106:     readyBound = false,
107:     
108:     // The functions to execute on DOM ready
109:     readyList = [],
110:
111:     // The ready event handler
112:     DOMContentLoaded,
113:
114:     // Save a reference to some core methods
115:     toString = Object.prototype.toString,
116:     hasOwnProperty = Object.prototype.hasOwnProperty,
117:     push = Array.prototype.push,
118:     slice = Array.prototype.slice,
119:     indexOf = Array.prototype.indexOf;
120:
121: jQuery.fn = jQuery.prototype = {
122:     init: function( selector, context ) {
123:
124:         var match, elem, ret, doc;
125:
126:         // Handle $(""), $(null), or $(undefined)
127:         if ( !selector ) {
128:             return this;
129:         }
130:
131:         // Handle $(DOMElement)
132:         if ( selector.nodeType ) {
133:             this.context = this[0] = selector;
134:             this.length = 1;
135:             return this;
136:         }
137:
138:         // Handle HTML strings
139:         if ( typeof selector === "string" ) {
140:             // Are we dealing with HTML string or an ID?
141:             match = quickExpr.exec( selector );
142:
143:             // Verify a match, and that no context was specified for #id
144:             if ( match && (match[1] || !context) ) {
145:
146:                 // HANDLE: $(html) -> $(array)
147:                 if ( match[1] ) {
148:                     doc = (context ? context.ownerDocument || context : document);
149:
150:                     // If a single string is passed in and it's a single tag
151:                     // just do a createElement and skip the rest
152:                     ret = rsingleTag.exec( selector );
153:
154:                     if ( ret ) {
155:                         if ( jQuery.isPlainObject( context ) ) {
156:                             selector = [ document.createElement( ret[1] ) ];
157:                             jQuery.fn.attr.call( selector, context, true );
158:
159:                         } else {
160:                             selector = [ doc.createElement( ret[1] ) ];
161:                         }
162:
163:                     } else {
164:                         ret = buildFragment( [ match[1] ], [ doc ] );
165:                         selector = (ret.cacheable ? ret.fragment.cloneNode(true) : ret.fragment).childNodes;
166:                     }
167:
168:                 // HANDLE: $("#id")
169:                 } else {
170:                     elem = document.getElementById( match[2] );
171:
172:                     if ( elem ) {
173:                         // Handle the case where IE and Opera return items
174:                         // by name instead of ID
175:                         if ( elem.id !== match[2] ) {
176:                             return rootjQuery.find( selector );
177:                         }
178:
179:                         // Otherwise, we inject the element directly into the jQuery object
180:                         this.length = 1;
181:                         this[0] = elem;
182:                     }
183:
184:                     this.context = document;
185:                     this.selector = selector;
186:                     return this;
187:                 }
188:
189:             // HANDLE: $("TAG")
190:             } else if ( !context && /^\w+$/.test( selector ) ) {
191:                 this.selector = selector;
192:                 this.context = document;
193:                 selector = document.getElementsByTagName( selector );
194:
195:             // HANDLE: $(expr, $(...))
196:             } else if ( !context || context.jquery ) {
197:                 return (context || rootjQuery).find( selector );
198:
199:             // HANDLE: $(expr, context)
200:             // (which is just equivalent to: $(context).find(expr)
201:             } else {
202:                 return jQuery( context ).find( selector );
203:             }
204:
205:         // HANDLE: $(function)
206:         // Shortcut for document ready
207:         } else if ( jQuery.isFunction( selector ) ) {
208:             return rootjQuery.ready( selector );
209:         }
210:
211:         if (selector.selector !== undefined) {
212:             this.selector = selector.selector;
213:             this.context = selector.context;
214:         }
215:
216:         return jQuery.isArray( selector ) ?
217:             this.setArray( selector ) :
218:             jQuery.makeArray( selector, this );
219:     },
220:
221:     // Start with an empty selector
222:     selector: "",
223:
224:     // The current version of jQuery being used
225:     jquery: "1.4.1",
226:
227:     // The default length of a jQuery object is 0
228:     length: 0,
229:
230:     // The number of elements contained in the matched element set
231:     size: function() {
232:         ///    <summary>
233:         ///        The number of elements currently matched.
234:         ///        Part of Core
235:         ///    </summary>
236:         ///    <returns type="Number" />
237:
238:         return this.length;
239:     },
240:
241:     toArray: function() {
242:         ///    <summary>
243:         ///        Retrieve all the DOM elements contained in the jQuery set, as an array.
244:         ///    </summary>
245:         ///    <returns type="Array" />
246:         return slice.call( this, 0 );
247:     },
248:
249:     // Get the Nth element in the matched element set OR
250:     // Get the whole matched element set as a clean array
251:     get: function( num ) {
252:         ///    <summary>
253:         ///        Access a single matched element. num is used to access the
254:         ///        Nth element matched.
255:         ///        Part of Core
256:         ///    </summary>
257:         ///    <returns type="Element" />
258:         ///    <param name="num" type="Number">
259:         ///        Access the element in the Nth position.
260:         ///    </param>
261:
262:         return num == null ?
263:
264:             // Return a 'clean' array
265:             this.toArray() :
266:
267:             // Return just the object
268:             ( num < 0 ? this.slice(num)[ 0 ] : this[ num ] );
269:     },
270:
271:     // Take an array of elements and push it onto the stack
272:     // (returning the new matched element set)
273:     pushStack: function( elems, name, selector ) {
274:         ///    <summary>
275:         ///        Set the jQuery object to an array of elements, while maintaining
276:         ///        the stack.
277:         ///        Part of Core
278:         ///    </summary>
279:         ///    <returns type="jQuery" />
280:         ///    <param name="elems" type="Elements">
281:         ///        An array of elements
282:         ///    </param>
283:
284:         // Build a new jQuery matched element set
285:         var ret = jQuery( elems || null );
286:
287:         // Add the old object onto the stack (as a reference)
288:         ret.prevObject = this;
289:
290:         ret.context = this.context;
291:
292:         if ( name === "find" ) {
293:             ret.selector = this.selector + (this.selector ? " " : "") + selector;
294:         } else if ( name ) {
295:             ret.selector = this.selector + "." + name + "(" + selector + ")";
296:         }
297:
298:         // Return the newly-formed element set
299:         return ret;
300:     },
301:
302:     // Force the current matched set of elements to become
303:     // the specified array of elements (destroying the stack in the process)
304:     // You should use pushStack() in order to do this, but maintain the stack
305:     setArray: function( elems ) {
306:         ///    <summary>
307:         ///        Set the jQuery object to an array of elements. This operation is
308:         ///        completely destructive - be sure to use .pushStack() if you wish to maintain
309:         ///        the jQuery stack.
310:         ///        Part of Core
311:         ///    </summary>
312:         ///    <returns type="jQuery" />
313:         ///    <param name="elems" type="Elements">
314:         ///        An array of elements
315:         ///    </param>
316:
317:         // Resetting the length to 0, then using the native Array push
318:         // is a super-fast way to populate an object with array-like properties
319:         this.length = 0;
320:         push.apply( this, elems );
321:
322:         return this;
323:     },
324:
325:     // Execute a callback for every element in the matched set.
326:     // (You can seed the arguments with an array of args, but this is
327:     // only used internally.)
328:     each: function( callback, args ) {
329:         ///    <summary>
330:         ///        Execute a function within the context of every matched element.
331:         ///        This means that every time the passed-in function is executed
332:         ///        (which is once for every element matched) the 'this' keyword
333:         ///        points to the specific element.
334:         ///        Additionally, the function, when executed, is passed a single
335:         ///        argument representing the position of the element in the matched
336:         ///        set.
337:         ///        Part of Core
338:         ///    </summary>
339:         ///    <returns type="jQuery" />
340:         ///    <param name="callback" type="Function">
341:         ///        A function to execute
342:         ///    </param>
343:
344:         return jQuery.each( this, callback, args );
345:     },
346:     
347:     ready: function( fn ) {
348:         ///    <summary>
349:         ///        Binds a function to be executed whenever the DOM is ready to be traversed and manipulated.
350:         ///    </summary>
351:         ///    <param name="fn" type="Function">The function to be executed when the DOM is ready.</param>
352:
353:         // Attach the listeners
354:         jQuery.bindReady();
355:
356:         // If the DOM is already ready
357:         if ( jQuery.isReady ) {
358:             // Execute the function immediately
359:             fn.call( document, jQuery );
360:
361:         // Otherwise, remember the function for later
362:         } else if ( readyList ) {
363:             // Add the function to the wait list
364:             readyList.push( fn );
365:         }
366:
367:         return this;
368:     },
369:     
370:     eq: function( i ) {
371:         ///    <summary>
372:         ///        Reduce the set of matched elements to a single element.
373:         ///        The position of the element in the set of matched elements
374:         ///        starts at 0 and goes to length - 1.
375:         ///        Part of Core
376:         ///    </summary>
377:         ///    <returns type="jQuery" />
378:         ///    <param name="num" type="Number">
379:         ///        pos The index of the element that you wish to limit to.
380:         ///    </param>
381:
382:         return i === -1 ?
383:             this.slice( i ) :
384:             this.slice( i, +i + 1 );
385:     },
386:
387:     first: function() {
388:         ///    <summary>
389:         ///        Reduce the set of matched elements to the first in the set.
390:         ///    </summary>
391:         ///    <returns type="jQuery" />
392:
393:         return this.eq( 0 );
394:     },
395:
396:     last: function() {
397:         ///    <summary>
398:         ///        Reduce the set of matched elements to the final one in the set.
399:         ///    </summary>
400:         ///    <returns type="jQuery" />
401:
402:         return this.eq( -1 );
403:     },
404:
405:     slice: function() {
406:         ///    <summary>
407:         ///        Selects a subset of the matched elements. Behaves exactly like the built-in Array slice method.
408:         ///    </summary>
409:         ///    <param name="start" type="Number" integer="true">Where to start the subset (0-based).</param>
410:         ///    <param name="end" optional="true" type="Number" integer="true">Where to end the subset (not including the end element itself).
411:         ///        If omitted, ends at the end of the selection</param>
412:         ///    <returns type="jQuery">The sliced elements</returns>
413:
414:         return this.pushStack( slice.apply( this, arguments ),
415:             "slice", slice.call(arguments).join(",") );
416:     },
417:
418:     map: function( callback ) {
419:         ///    <summary>
420:         ///        This member is internal.
421:         ///    </summary>
422:         ///    <private />
423:         ///    <returns type="jQuery" />
424:
425:         return this.pushStack( jQuery.map(this, function( elem, i ) {
426:             return callback.call( elem, i, elem );
427:         }));
428:     },
429:     
430:     end: function() {
431:         ///    <summary>
432:         ///        End the most recent 'destructive' operation, reverting the list of matched elements
433:         ///        back to its previous state. After an end operation, the list of matched elements will
434:         ///        revert to the last state of matched elements.
435:         ///        If there was no destructive operation before, an empty set is returned.
436:         ///        Part of DOM/Traversing
437:         ///    </summary>
438:         ///    <returns type="jQuery" />
439:
440:         return this.prevObject || jQuery(null);
441:     },
442:
443:     // For internal use only.
444:     // Behaves like an Array's method, not like a jQuery method.
445:     push: push,
446:     sort: [].sort,
447:     splice: [].splice
448: };
449:
450: // Give the init function the jQuery prototype for later instantiation
451: jQuery.fn.init.prototype = jQuery.fn;
452:
453: jQuery.extend = jQuery.fn.extend = function() {
454:     ///    <summary>
455:     ///        Extend one object with one or more others, returning the original,
456:     ///        modified, object. This is a great utility for simple inheritance.
457:     ///        jQuery.extend(settings, options);
458:     ///        var settings = jQuery.extend({}, defaults, options);
459:     ///        Part of JavaScript
460:     ///    </summary>
461:     ///    <param name="target" type="Object">
462:     ///         The object to extend
463:     ///    </param>
464:     ///    <param name="prop1" type="Object">
465:     ///         The object that will be merged into the first.
466:     ///    </param>
467:     ///    <param name="propN" type="Object" optional="true" parameterArray="true">
468:     ///         (optional) More objects to merge into the first
469:     ///    </param>
470:     ///    <returns type="Object" />
471:
472:     // copy reference to target object
473:     var target = arguments[0] || {}, i = 1, length = arguments.length, deep = false, options, name, src, copy;
474:
475:     // Handle a deep copy situation
476:     if ( typeof target === "boolean" ) {
477:         deep = target;
478:         target = arguments[1] || {};
479:         // skip the boolean and the target
480:         i = 2;
481:     }
482:
483:     // Handle case when target is a string or something (possible in deep copy)
484:     if ( typeof target !== "object" && !jQuery.isFunction(target) ) {
485:         target = {};
486:     }
487:
488:     // extend jQuery itself if only one argument is passed
489:     if ( length === i ) {
490:         target = this;
491:         --i;
492:     }
493:
494:     for ( ; i < length; i++ ) {
495:         // Only deal with non-null/undefined values
496:         if ( (options = arguments[ i ]) != null ) {
497:             // Extend the base object
498:             for ( name in options ) {
499:                 src = target[ name ];
500:                 copy = options[ name ];
501:
502:                 // Prevent never-ending loop
503:                 if ( target === copy ) {
504:                     continue;
505:                 }
506:
507:                 // Recurse if we're merging object literal values or arrays
508:                 if ( deep && copy && ( jQuery.isPlainObject(copy) || jQuery.isArray(copy) ) ) {
509:                     var clone = src && ( jQuery.isPlainObject(src) || jQuery.isArray(src) ) ? src
510:                         : jQuery.isArray(copy) ? [] : {};
511:
512:                     // Never move original objects, clone them
513:                     target[ name ] = jQuery.extend( deep, clone, copy );
514:
515:                 // Don't bring in undefined values
516:                 } else if ( copy !== undefined ) {
517:                     target[ name ] = copy;
518:                 }
519:             }
520:         }
521:     }
522:
523:     // Return the modified object
524:     return target;
525: };
526:
527: jQuery.extend({
528:     noConflict: function( deep ) {
529:         ///    <summary>
530:         ///        Run this function to give control of the $ variable back
531:         ///        to whichever library first implemented it. This helps to make
532:         ///        sure that jQuery doesn't conflict with the $ object
533:         ///        of other libraries.
534:         ///        By using this function, you will only be able to access jQuery
535:         ///        using the 'jQuery' variable. For example, where you used to do
536:         ///        $("div p"), you now must do jQuery("div p").
537:         ///        Part of Core
538:         ///    </summary>
539:         ///    <returns type="undefined" />
540:
541:         window.$ = _$;
542:
543:         if ( deep ) {
544:             window.jQuery = _jQuery;
545:         }
546:
547:         return jQuery;
548:     },
549:     
550:     // Is the DOM ready to be used? Set to true once it occurs.
551:     isReady: false,
552:     
553:     // Handle when the DOM is ready
554:     ready: function() {
555:         ///    <summary>
556:         ///        This method is internal.
557:         ///    </summary>
558:         ///    <private />
559:
560:         // Make sure that the DOM is not already loaded
561:         if ( !jQuery.isReady ) {
562:             // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443).
563:             if ( !document.body ) {
564:                 return setTimeout( jQuery.ready, 13 );
565:             }
566:
567:             // Remember that the DOM is ready
568:             jQuery.isReady = true;
569:
570:             // If there are functions bound, to execute
571:             if ( readyList ) {
572:                 // Execute all of them
573:                 var fn, i = 0;
574:                 while ( (fn = readyList[ i++ ]) ) {
575:                     fn.call( document, jQuery );
576:                 }
577:
578:                 // Reset the list of functions
579:                 readyList = null;
580:             }
581:
582:             // Trigger any bound ready events
583:             if ( jQuery.fn.triggerHandler ) {
584:                 jQuery( document ).triggerHandler( "ready" );
585:             }
586:         }
587:     },
588:     
589:     bindReady: function() {
590:         if ( readyBound ) {
591:             return;
592:         }
593:
594:         readyBound = true;
595:
596:         // Catch cases where $(document).ready() is called after the
597:         // browser event has already occurred.
598:         if ( document.readyState === "complete" ) {
599:             return jQuery.ready();
600:         }
601:
602:         // Mozilla, Opera and webkit nightlies currently support this event
603:         if ( document.addEventListener ) {
604:             // Use the handy event callback
605:             document.addEventListener( "DOMContentLoaded", DOMContentLoaded, false );
606:             
607:             // A fallback to window.onload, that will always work
608:             window.addEventListener( "load", jQuery.ready, false );
609:
610:         // If IE event model is used
611:         } else if ( document.attachEvent ) {
612:             // ensure firing before onload,
613:             // maybe late but safe also for iframes
614:             document.attachEvent("onreadystatechange", DOMContentLoaded);
615:             
616:             // A fallback to window.onload, that will always work
617:             window.attachEvent( "onload", jQuery.ready );
618:
619:             // If IE and not a frame
620:             // continually check to see if the document is ready
621:             var toplevel = false;
622:
623:             try {
624:                 toplevel = window.frameElement == null;
625:             } catch(e) {}
626:
627:             if ( document.documentElement.doScroll && toplevel ) {
628:                 doScrollCheck();
629:             }
630:         }
631:     },
632:
633:     // See test/unit/core.js for details concerning isFunction.
634:     // Since version 1.3, DOM methods and functions like alert
635:     // aren't supported. They return false on IE (#2968).
636:     isFunction: function( obj ) {
637:         ///    <summary>
638:         ///        Determines if the parameter passed is a function.
639:         ///    </summary>
640:         ///    <param name="obj" type="Object">The object to check</param>
641:         ///    <returns type="Boolean">True if the parameter is a function; otherwise false.</returns>
642:
643:         return toString.call(obj) === "[object Function]";
644:     },
645:
646:     isArray: function( obj ) {
647:         ///    <summary>
648:         ///        Determine if the parameter passed is an array.
649:         ///    </summary>
650:         ///    <param name="obj" type="Object">Object to test whether or not it is an array.</param>
651:         ///    <returns type="Boolean">True if the parameter is a function; otherwise false.</returns>
652:
653:         return toString.call(obj) === "[object Array]";
654:     },
655:
656:     isPlainObject: function( obj ) {
657:         ///    <summary>
658:         ///        Check to see if an object is a plain object (created using "{}" or "new Object").
659:         ///    </summary>
660:         ///    <param name="obj" type="Object">
661:         ///        The object that will be checked to see if it's a plain object.
662:         ///    </param>
663:         ///    <returns type="Boolean" />
664:
665:         // Must be an Object.
666:         // Because of IE, we also have to check the presence of the constructor property.
667:         // Make sure that DOM nodes and window objects don't pass through, as well
668:         if ( !obj || toString.call(obj) !== "[object Object]" || obj.nodeType || obj.setInterval ) {
669:             return false;
670:         }
671:         
672:         // Not own constructor property must be Object
673:         if ( obj.constructor
674:             && !hasOwnProperty.call(obj, "constructor")
675:             && !hasOwnProperty.call(obj.constructor.prototype, "isPrototypeOf") ) {
676:             return false;
677:         }
678:         
679:         // Own properties are enumerated firstly, so to speed up,
680:         // if last one is own, then all properties are own.
681:     
682:         var key;
683:         for ( key in obj ) {}
684:         
685:         return key === undefined || hasOwnProperty.call( obj, key );
686:     },
687:
688:     isEmptyObject: function( obj ) {
689:         ///    <summary>
690:         ///        Check to see if an object is empty (contains no properties).
691:         ///    </summary>
692:         ///    <param name="obj" type="Object">
693:         ///        The object that will be checked to see if it's empty.
694:         ///    </param>
695:         ///    <returns type="Boolean" />
696:
697:         for ( var name in obj ) {
698:             return false;
699:         }
700:         return true;
701:     },
702:     
703:     error: function( msg ) {
704:         throw msg;
705:     },
706:     
707:     parseJSON: function( data ) {
708:         if ( typeof data !== "string" || !data ) {
709:             return null;
710:         }
711:         
712:         // Make sure the incoming data is actual JSON
713:         // Logic borrowed from http://json.org/json2.js
714:         if ( /^[\],:{}\s]*$/.test(data.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g, "@")
715:             .replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g, "]")
716:             .replace(/(?:^|:|,)(?:\s*\[)+/g, "")) ) {
717:
718:             // Try to use the native JSON parser first
719:             return window.JSON && window.JSON.parse ?
720:                 window.JSON.parse( data ) :
721:                 (new Function("return " + data))();
722:
723:         } else {
724:             jQuery.error( "Invalid JSON: " + data );
725:         }
726:     },
727:
728:     noop: function() {
729:         ///    <summary>
730:         ///        An empty function.
731:         ///    </summary>
732:         ///    <returns type="Function" />
733:     },
734:
735:     // Evalulates a script in a global context
736:     globalEval: function( data ) {
737:         ///    <summary>
738:         ///        Internally evaluates a script in a global context.
739:         ///    </summary>
740:         ///    <private />
741:
742:         if ( data && rnotwhite.test(data) ) {
743:             // Inspired by code by Andrea Giammarchi
744:             // http://webreflection.blogspot.com/2007/08/global-scope-evaluation-and-dom.html
745:             var head = document.getElementsByTagName("head")[0] || document.documentElement,
746:                 script = document.createElement("script");
747:
748:             script.type = "text/javascript";
749:
750:             if ( jQuery.support.scriptEval ) {
751:                 script.appendChild( document.createTextNode( data ) );
752:             } else {
753:                 script.text = data;
754:             }
755:
756:             // Use insertBefore instead of appendChild to circumvent an IE6 bug.
757:             // This arises when a base node is used (#2709).
758:             head.insertBefore( script, head.firstChild );
759:             head.removeChild( script );
760:         }
761:     },
762:
763:     nodeName: function( elem, name ) {
764:         ///    <summary>
765:         ///        Checks whether the specified element has the specified DOM node name.
766:         ///    </summary>
767:         ///    <param name="elem" type="Element">The element to examine</param>
768:         ///    <param name="name" type="String">The node name to check</param>
769:         ///    <returns type="Boolean">True if the specified node name matches the node's DOM node name; otherwise false</returns>
770:
771:         return elem.nodeName && elem.nodeName.toUpperCase() === name.toUpperCase();
772:     },
773:
774:     // args is for internal usage only
775:     each: function( object, callback, args ) {
776:         ///    <summary>
777:         ///        A generic iterator function, which can be used to seemlessly
778:         ///        iterate over both objects and arrays. This function is not the same
779:         ///        as $().each() - which is used to iterate, exclusively, over a jQuery
780:         ///        object. This function can be used to iterate over anything.
781:         ///        The callback has two arguments:the key (objects) or index (arrays) as first
782:         ///        the first, and the value as the second.
783:         ///        Part of JavaScript
784:         ///    </summary>
785:         ///    <param name="obj" type="Object">
786:         ///         The object, or array, to iterate over.
787:         ///    </param>
788:         ///    <param name="fn" type="Function">
789:         ///         The function that will be executed on every object.
790:         ///    </param>
791:         ///    <returns type="Object" />
792:
793:         var name, i = 0,
794:             length = object.length,
795:             isObj = length === undefined || jQuery.isFunction(object);
796:
797:         if ( args ) {
798:             if ( isObj ) {
799:                 for ( name in object ) {
800:                     if ( callback.apply( object[ name ], args ) === false ) {
801:                         break;
802:                     }
803:                 }
804:             } else {
805:                 for ( ; i < length; ) {
806:                     if ( callback.apply( object[ i++ ], args ) === false ) {
807:                         break;
808:                     }
809:                 }
810:             }
811:
812:         // A special, fast, case for the most common use of each
813:         } else {
814:             if ( isObj ) {
815:                 for ( name in object ) {
816:                     if ( callback.call( object[ name ], name, object[ name ] ) === false ) {
817:                         break;
818:                     }
819:                 }
820:             } else {
821:                 for ( var value = object[0];
822:                     i < length && callback.call( value, i, value ) !== false; value = object[++i] ) {}
823:             }
824:         }
825:
826:         return object;
827:     },
828:
829:     trim: function( text ) {
830:         ///    <summary>
831:         ///        Remove the whitespace from the beginning and end of a string.
832:         ///        Part of JavaScript
833:         ///    </summary>
834:         ///    <returns type="String" />
835:         ///    <param name="text" type="String">
836:         ///        The string to trim.
837:         ///    </param>
838:
839:         return (text || "").replace( rtrim, "" );
840:     },
841:
842:     // results is for internal usage only
843:     makeArray: function( array, results ) {
844:         ///    <summary>
845:         ///        Turns anything into a true array. This is an internal method.
846:         ///    </summary>
847:         ///    <param name="array" type="Object">Anything to turn into an actual Array</param>
848:         ///    <returns type="Array" />
849:         ///    <private />
850:
851:         var ret = results || [];
852:
853:         if ( array != null ) {
854:             // The window, strings (and functions) also have 'length'
855:             // The extra typeof function check is to prevent crashes
856:             // in Safari 2 (See: #3039)
857:             if ( array.length == null || typeof array === "string" || jQuery.isFunction(array) || (typeof array !== "function" && array.setInterval) ) {
858:                 push.call( ret, array );
859:             } else {
860:                 jQuery.merge( ret, array );
861:             }
862:         }
863:
864:         return ret;
865:     },
866:
867:     inArray: function( elem, array ) {
868:         if ( array.indexOf ) {
869:             return array.indexOf( elem );
870:         }
871:
872:         for ( var i = 0, length = array.length; i < length; i++ ) {
873:             if ( array[ i ] === elem ) {
874:                 return i;
875:             }
876:         }
877:
878:         return -1;
879:     },
880:
881:     merge: function( first, second ) {
882:         ///    <summary>
883:         ///        Merge two arrays together, removing all duplicates.
884:         ///        The new array is: All the results from the first array, followed
885:         ///        by the unique results from the second array.
886:         ///        Part of JavaScript
887:         ///    </summary>
888:         ///    <returns type="Array" />
889:         ///    <param name="first" type="Array">
890:         ///         The first array to merge.
891:         ///    </param>
892:         ///    <param name="second" type="Array">
893:         ///         The second array to merge.
894:         ///    </param>
895:
896:         var i = first.length, j = 0;
897:
898:         if ( typeof second.length === "number" ) {
899:             for ( var l = second.length; j < l; j++ ) {
900:                 first[ i++ ] = second[ j ];
901:             }
902:         } else {
903:             while ( second[j] !== undefined ) {
904:                 first[ i++ ] = second[ j++ ];
905:             }
906:         }
907:
908:         first.length = i;
909:
910:         return first;
911:     },
912:
913:     grep: function( elems, callback, inv ) {
914:         ///    <summary>
915:         ///        Filter items out of an array, by using a filter function.
916:         ///        The specified function will be passed two arguments: The
917:         ///        current array item and the index of the item in the array. The
918:         ///        function must return 'true' to keep the item in the array,
919:         ///        false to remove it.
920:         ///        });
921:         ///        Part of JavaScript
922:         ///    </summary>
923:         ///    <returns type="Array" />
924:         ///    <param name="elems" type="Array">
925:         ///        array The Array to find items in.
926:         ///    </param>
927:         ///    <param name="fn" type="Function">
928:         ///         The function to process each item against.
929:         ///    </param>
930:         ///    <param name="inv" type="Boolean">
931:         ///         Invert the selection - select the opposite of the function.
932:         ///    </param>
933:
934:         var ret = [];
935:
936:         // Go through the array, only saving the items
937:         // that pass the validator function
938:         for ( var i = 0, length = elems.length; i < length; i++ ) {
939:             if ( !inv !== !callback( elems[ i ], i ) ) {
940:                 ret.push( elems[ i ] );
941:             }
942:         }
943:
944:         return ret;
945:     },
946:
947:     // arg is for internal usage only
948:     map: function( elems, callback, arg ) {
949:         ///    <summary>
950:         ///        Translate all items in an array to another array of items.
951:         ///        The translation function that is provided to this method is
952:         ///        called for each item in the array and is passed one argument:
953:         ///        The item to be translated.
954:         ///        The function can then return the translated value, 'null'
955:         ///        (to remove the item), or an array of values - which will
956:         ///        be flattened into the full array.
957:         ///        Part of JavaScript
958:         ///    </summary>
959:         ///    <returns type="Array" />
960:         ///    <param name="elems" type="Array">
961:         ///        array The Array to translate.
962:         ///    </param>
963:         ///    <param name="fn" type="Function">
964:         ///         The function to process each item against.
965:         ///    </param>
966:
967:         var ret = [], value;
968:
969:         // Go through the array, translating each of the items to their
970:         // new value (or values).
971:         for ( var i = 0, length = elems.length; i < length; i++ ) {
972:             value = callback( elems[ i ], i, arg );
973:
974:             if ( value != null ) {
975:                 ret[ ret.length ] = value;
976:             }
977:         }
978:
979:         return ret.concat.apply( [], ret );
980:     },
981:
982:     // A global GUID counter for objects
983:     guid: 1,
984:
985:     proxy: function( fn, proxy, thisObject ) {
986:         ///    <summary>
987:         ///        Takes a function and returns a new one that will always have a particular scope.
988:         ///    </summary>
989:         ///    <param name="fn" type="Function">
990:         ///        The function whose scope will be changed.
991:         ///    </param>
992:         ///    <param name="proxy" type="Object">
993:         ///        The object to which the scope of the function should be set.
994:         ///    </param>
995:         ///    <returns type="Function" />
996:
997:         if ( arguments.length === 2 ) {
998:             if ( typeof proxy === "string" ) {
999:                 thisObject = fn;
1000:                 fn = thisObject[ proxy ];
1001:                 proxy = undefined;
1002:
1003:             } else if ( proxy && !jQuery.isFunction( proxy ) ) {
1004:                 thisObject = proxy;
1005:                 proxy = undefined;
1006:             }
1007:         }
1008:
1009:         if ( !proxy && fn ) {
1010:             proxy = function() {
1011:                 return fn.apply( thisObject || this, arguments );
1012:             };
1013:         }
1014:
1015:         // Set the guid of unique handler to the same of original handler, so it can be removed
1016:         if ( fn ) {
1017:             proxy.guid = fn.guid = fn.guid || proxy.guid || jQuery.guid++;
1018:         }
1019:
1020:         // So proxy can be declared as an argument
1021:         return proxy;
1022:     },
1023:
1024:     // Use of jQuery.browser is frowned upon.
1025:     // More details: http://docs.jquery.com/Utilities/jQuery.browser
1026:     uaMatch: function( ua ) {
1027:         ua = ua.toLowerCase();
1028:
1029:         var match = /(webkit)[ \/]([\w.]+)/.exec( ua ) ||
1030:             /(opera)(?:.*version)?[ \/]([\w.]+)/.exec( ua ) ||
1031:             /(msie) ([\w.]+)/.exec( ua ) ||
1032:             !/compatible/.test( ua ) && /(mozilla)(?:.*? rv:([\w.]+))?/.exec( ua ) ||
1033:              [];
1034:
1035:         return { browser: match[1] || "", version: match[2] || "0" };
1036:     },
1037:
1038:     browser: {}
1039: });
1040:
1041: browserMatch = jQuery.uaMatch( userAgent );
1042: if ( browserMatch.browser ) {
1043:     jQuery.browser[ browserMatch.browser ] = true;
1044:     jQuery.browser.version = browserMatch.version;
1045: }
1046:
1047: // Deprecated, use jQuery.browser.webkit instead
1048: if ( jQuery.browser.webkit ) {
1049:     jQuery.browser.safari = true;
1050: }
1051:
1052: if ( indexOf ) {
1053:     jQuery.inArray = function( elem, array ) {
1054:         ///    <summary>
1055:         ///        Determines the index of the first parameter in the array.
1056:         ///    </summary>
1057:         ///    <param name="elem">The value to see if it exists in the array.</param>
1058:         ///    <param name="array" type="Array">The array to look through for the value</param>
1059:         ///    <returns type="Number" integer="true">The 0-based index of the item if it was found, otherwise -1.</returns>
1060:
1061:         return indexOf.call( array, elem );
1062:     };
1063: }
1064:
1065: // All jQuery objects should point back to these
1066: rootjQuery = jQuery(document);
1067:
1068: // Cleanup functions for the document ready method
1069: if ( document.addEventListener ) {
1070:     DOMContentLoaded = function() {
1071:         document.removeEventListener( "DOMContentLoaded", DOMContentLoaded, false );
1072:         jQuery.ready();
1073:     };
1074:
1075: } else if ( document.attachEvent ) {
1076:     DOMContentLoaded = function() {
1077:         // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443).
1078:         if ( document.readyState === "complete" ) {
1079:             document.detachEvent( "onreadystatechange", DOMContentLoaded );
1080:             jQuery.ready();
1081:         }
1082:     };
1083: }
1084:
1085: // The DOM ready check for Internet Explorer
1086: function doScrollCheck() {
1087:     if ( jQuery.isReady ) {
1088:         return;
1089:     }
1090:
1091:     try {
1092:         // If IE is used, use the trick by Diego Perini
1093:         // http://javascript.nwbox.com/IEContentLoaded/
1094:         document.documentElement.doScroll("left");
1095:     } catch( error ) {
1096:         setTimeout( doScrollCheck, 1 );
1097:         return;
1098:     }
1099:
1100:     // and execute any waiting functions
1101:     jQuery.ready();
1102: }
1103:
1104: function evalScript( i, elem ) {
1105:     ///    <summary>
1106:     ///        This method is internal.
1107:     ///    </summary>
1108:     /// <private />
1109:
1110:     if ( elem.src ) {
1111:         jQuery.ajax({
1112:             url: elem.src,
1113:             async: false,
1114:             dataType: "script"
1115:         });
1116:     } else {
1117:         jQuery.globalEval( elem.text || elem.textContent || elem.innerHTML || "" );
1118:     }
1119:
1120:     if ( elem.parentNode ) {
1121:         elem.parentNode.removeChild( elem );
1122:     }
1123: }
1124:
1125: // Mutifunctional method to get and set values to a collection
1126: // The value/s can be optionally by executed if its a function
1127: function access( elems, key, value, exec, fn, pass ) {
1128:     var length = elems.length;
1129:     
1130:     // Setting many attributes
1131:     if ( typeof key === "object" ) {
1132:         for ( var k in key ) {
1133:             access( elems, k, key[k], exec, fn, value );
1134:         }
1135:         return elems;
1136:     }
1137:     
1138:     // Setting one attribute
1139:     if ( value !== undefined ) {
1140:         // Optionally, function values get executed if exec is true
1141:         exec = !pass && exec && jQuery.isFunction(value);
1142:         
1143:         for ( var i = 0; i < length; i++ ) {
1144:             fn( elems[i], key, exec ? value.call( elems[i], i, fn( elems[i], key ) ) : value, pass );
1145:         }
1146:         
1147:         return elems;
1148:     }
1149:     
1150:     // Getting an attribute
1151:     return length ? fn( elems[0], key ) : null;
1152: }
1153:
1154: function now() {
1155:     ///    <summary>
1156:     ///        Gets the current date.
1157:     ///    </summary>
1158:     ///    <returns type="Date">The current date.</returns>
1159:
1160:     return (new Date).getTime();
1161: }
1162:
1163: // [vsdoc] The following function has been modified for IntelliSense.
1164: // [vsdoc] Stubbing support properties to "false" for IntelliSense compat.
1165: (function() {
1166:
1167:     jQuery.support = {};
1168:
1169:     //    var root = document.documentElement,
1170:     //        script = document.createElement("script"),
1171:     //        div = document.createElement("div"),
1172:     //        id = "script" + now();
1173:
1174:     //    div.style.display = "none";
1175:     //    div.innerHTML = " <link/><table></table><a href='/a' style='color:red;float:left;opacity:.55;'>a</a><input type='checkbox'/>";
1176:
1177:     //    var all = div.getElementsByTagName("*"),
1178:     //        a = div.getElementsByTagName("a")[0];
1179:
1180:     //    // Can't get basic test support
1181:     //    if ( !all || !all.length || !a ) {
1182:     //        return;
1183:     //    }
1184:
1185:     jQuery.support = {
1186:         // IE strips leading whitespace when .innerHTML is used
1187:         leadingWhitespace: false,
1188:
1189:         // Make sure that tbody elements aren't automatically inserted
1190:         // IE will insert them into empty tables
1191:         tbody: false,
1192:
1193:         // Make sure that link elements get serialized correctly by innerHTML
1194:         // This requires a wrapper element in IE
1195:         htmlSerialize: false,
1196:
1197:         // Get the style information from getAttribute
1198:         // (IE uses .cssText insted)
1199:         style: false,
1200:
1201:         // Make sure that URLs aren't manipulated
1202:         // (IE normalizes it by default)
1203:         hrefNormalized: false,
1204:
1205:         // Make sure that element opacity exists
1206:         // (IE uses filter instead)
1207:         // Use a regex to work around a WebKit issue. See #5145
1208:         opacity: false,
1209:
1210:         // Verify style float existence
1211:         // (IE uses styleFloat instead of cssFloat)
1212:         cssFloat: false,
1213:
1214:         // Make sure that if no value is specified for a checkbox
1215:         // that it defaults to "on".
1216:         // (WebKit defaults to "" instead)
1217:         checkOn: false,
1218:
1219:         // Make sure that a selected-by-default option has a working selected property.
1220:         // (WebKit defaults to false instead of true, IE too, if it's in an optgroup)
1221:         optSelected: false,
1222:
1223:         // Will be defined later
1224:         checkClone: false,
1225:         scriptEval: false,
1226:         noCloneEvent: false,
1227:         boxModel: false
1228:     };
1229:
1230:     //    script.type = "text/javascript";
1231:     //    try {
1232:     //        script.appendChild( document.createTextNode( "window." + id + "=1;" ) );
1233:     //    } catch(e) {}
1234:
1235:     //    root.insertBefore( script, root.firstChild );
1236:
1237:     //    // Make sure that the execution of code works by injecting a script
1238:     //    // tag with appendChild/createTextNode
1239:     //    // (IE doesn't support this, fails, and uses .text instead)
1240:     //    if ( window[ id ] ) {
1241:     //        jQuery.support.scriptEval = true;
1242:     //        delete window[ id ];
1243:     //    }
1244:
1245:     //    root.removeChild( script );
1246:
1247:     //    if ( div.attachEvent && div.fireEvent ) {
1248:     //        div.attachEvent("onclick", function click() {
1249:     //            // Cloning a node shouldn't copy over any
1250:     //            // bound event handlers (IE does this)
1251:     //            jQuery.support.noCloneEvent = false;
1252:     //            div.detachEvent("onclick", click);
1253:     //        });
1254:     //        div.cloneNode(true).fireEvent("onclick");
1255:     //    }
1256:
1257:     //    div = document.createElement("div");
1258:     //    div.innerHTML = "<input type='radio' name='radiotest' checked='checked'/>";
1259:
1260:     //    var fragment = document.createDocumentFragment();
1261:     //    fragment.appendChild( div.firstChild );
1262:
1263:     //    // WebKit doesn't clone checked state correctly in fragments
1264:     //    jQuery.support.checkClone = fragment.cloneNode(true).cloneNode(true).lastChild.checked;
1265:
1266:     //    // Figure out if the W3C box model works as expected
1267:     //    // document.body must exist before we can do this
1268:     //    jQuery(function() {
1269:     //        var div = document.createElement("div");
1270:     //        div.style.width = div.style.paddingLeft = "1px";
1271:
1272:     //        document.body.appendChild( div );
1273:     //        jQuery.boxModel = jQuery.support.boxModel = div.offsetWidth === 2;
1274:     //        document.body.removeChild( div ).style.display = 'none';
1275:     //        div = null;
1276:     //    });
1277:
1278:     //    // Technique from Juriy Zaytsev
1279:     //    // http://thinkweb2.com/projects/prototype/detecting-event-support-without-browser-sniffing/
1280:     //    var eventSupported = function( eventName ) {
1281:     //        var el = document.createElement("div");
1282:     //        eventName = "on" + eventName;
1283:
1284:     //        var isSupported = (eventName in el);
1285:     //        if ( !isSupported ) {
1286:     //            el.setAttribute(eventName, "return;");
1287:     //            isSupported = typeof el[eventName] === "function";
1288:     //        }
1289:     //        el = null;
1290:
1291:     //        return isSupported;
1292:     //    };
1293:     
1294:     jQuery.support.submitBubbles = false;
1295:     jQuery.support.changeBubbles = false;
1296:
1297:     //    // release memory in IE
1298:     //    root = script = div = all = a = null;
1299: })();
1300:
1301: jQuery.props = {
1302:     "for": "htmlFor",
1303:     "class": "className",
1304:     readonly: "readOnly",
1305:     maxlength: "maxLength",
1306:     cellspacing: "cellSpacing",
1307:     rowspan: "rowSpan",
1308:     colspan: "colSpan",
1309:     tabindex: "tabIndex",
1310:     usemap: "useMap",
1311:     frameborder: "frameBorder"
1312: };
1313: var expando = "jQuery" + now(), uuid = 0, windowData = {};
1314: var emptyObject = {};
1315:
1316: jQuery.extend({
1317:     cache: {},
1318:     
1319:     expando:expando,
1320:
1321:     // The following elements throw uncatchable exceptions if you
1322:     // attempt to add expando properties to them.
1323:     noData: {
1324:         "embed": true,
1325:         "object": true,
1326:         "applet": true
1327:     },
1328:
1329:     data: function( elem, name, data ) {
1330:         ///    <summary>
1331:         ///        Store arbitrary data associated with the specified element.
1332:         ///    </summary>
1333:         ///    <param name="elem" type="Element">
1334:         ///        The DOM element to associate with the data.
1335:         ///    </param>
1336:         ///    <param name="name" type="String">
1337:         ///        A string naming the piece of data to set.
1338:         ///    </param>
1339:         ///    <param name="value" type="Object">
1340:         ///        The new data value.
1341:         ///    </param>
1342:         ///    <returns type="jQuery" />
1343:
1344:         if ( elem.nodeName && jQuery.noData[elem.nodeName.toLowerCase()] ) {
1345:             return;
1346:         }
1347:
1348:         elem = elem == window ?
1349:             windowData :
1350:             elem;
1351:
1352:         var id = elem[ expando ], cache = jQuery.cache, thisCache;
1353:
1354:         // Handle the case where there's no name immediately
1355:         if ( !name && !id ) {
1356:             return null;
1357:         }
1358:
1359:         // Compute a unique ID for the element
1360:         if ( !id ) {
1361:             id = ++uuid;
1362:         }
1363:
1364:         // Avoid generating a new cache unless none exists and we
1365:         // want to manipulate it.
1366:         if ( typeof name === "object" ) {
1367:             elem[ expando ] = id;
1368:             thisCache = cache[ id ] = jQuery.extend(true, {}, name);
1369:         } else if ( cache[ id ] ) {
1370:             thisCache = cache[ id ];
1371:         } else if ( typeof data === "undefined" ) {
1372:             thisCache = emptyObject;
1373:         } else {
1374:             thisCache = cache[ id ] = {};
1375:         }
1376:
1377:         // Prevent overriding the named cache with undefined values
1378:         if ( data !== undefined ) {
1379:             elem[ expando ] = id;
1380:             thisCache[ name ] = data;
1381:         }
1382:
1383:         return typeof name === "string" ? thisCache[ name ] : thisCache;
1384:     },
1385:
1386:     removeData: function( elem, name ) {
1387:         if ( elem.nodeName && jQuery.noData[elem.nodeName.toLowerCase()] ) {
1388:             return;
1389:         }
1390:
1391:         elem = elem == window ?
1392:             windowData :
1393:             elem;
1394:
1395:         var id = elem[ expando ], cache = jQuery.cache, thisCache = cache[ id ];
1396:
1397:         // If we want to remove a specific section of the element's data
1398:         if ( name ) {
1399:             if ( thisCache ) {
1400:                 // Remove the section of cache data
1401:                 delete thisCache[ name ];
1402:
1403:                 // If we've removed all the data, remove the element's cache
1404:                 if ( jQuery.isEmptyObject(thisCache) ) {
1405:                     jQuery.removeData( elem );
1406:                 }
1407:             }
1408:
1409:         // Otherwise, we want to remove all of the element's data
1410:         } else {
1411:             // Clean up the element expando
1412:             try {
1413:                 delete elem[ expando ];
1414:             } catch( e ) {
1415:                 // IE has trouble directly removing the expando
1416:                 // but it's ok with using removeAttribute
1417:                 if ( elem.removeAttribute ) {
1418:                     elem.removeAttribute( expando );
1419:                 }
1420:             }
1421:
1422:             // Completely remove the data cache
1423:             delete cache[ id ];
1424:         }
1425:     }
1426: });
1427:
1428: jQuery.fn.extend({
1429:     data: function( key, value ) {
1430:         ///    <summary>
1431:         ///        Store arbitrary data associated with the matched elements.
1432:         ///    </summary>
1433:         ///    <param name="key" type="String">
1434:         ///        A string naming the piece of data to set.
1435:         ///    </param>
1436:         ///    <param name="value" type="Object">
1437:         ///        The new data value.
1438:         ///    </param>
1439:         ///    <returns type="jQuery" />
1440:
1441:         if ( typeof key === "undefined" && this.length ) {
1442:             return jQuery.data( this[0] );
1443:
1444:         } else if ( typeof key === "object" ) {
1445:             return this.each(function() {
1446:                 jQuery.data( this, key );
1447:             });
1448:         }
1449:
1450:         var parts = key.split(".");
1451:         parts[1] = parts[1] ? "." + parts[1] : "";
1452:
1453:         if ( value === undefined ) {
1454:             var data = this.triggerHandler("getData" + parts[1] + "!", [parts[0]]);
1455:
1456:             if ( data === undefined && this.length ) {
1457:                 data = jQuery.data( this[0], key );
1458:             }
1459:             return data === undefined && parts[1] ?
1460:                 this.data( parts[0] ) :
1461:                 data;
1462:         } else {
1463:             return this.trigger("setData" + parts[1] + "!", [parts[0], value]).each(function() {
1464:                 jQuery.data( this, key, value );
1465:             });
1466:         }
1467:     },
1468:
1469:     removeData: function( key ) {
1470:         return this.each(function() {
1471:             jQuery.removeData( this, key );
1472:         });
1473:     }
1474: });
1475: jQuery.extend({
1476:     queue: function( elem, type, data ) {
1477:         if ( !elem ) {
1478:             return;
1479:         }
1480:
1481:         type = (type || "fx") + "queue";
1482:         var q = jQuery.data( elem, type );
1483:
1484:         // Speed up dequeue by getting out quickly if this is just a lookup
1485:         if ( !data ) {
1486:             return q || [];
1487:         }
1488:
1489:         if ( !q || jQuery.isArray(data) ) {
1490:             q = jQuery.data( elem, type, jQuery.makeArray(data) );
1491:
1492:         } else {
1493:             q.push( data );
1494:         }
1495:
1496:         return q;
1497:     },
1498:
1499:     dequeue: function( elem, type ) {
1500:         type = type || "fx";
1501:
1502:         var queue = jQuery.queue( elem, type ), fn = queue.shift();
1503:
1504:         // If the fx queue is dequeued, always remove the progress sentinel
1505:         if ( fn === "inprogress" ) {
1506:             fn = queue.shift();
1507:         }
1508:
1509:         if ( fn ) {
1510:             // Add a progress sentinel to prevent the fx queue from being
1511:             // automatically dequeued
1512:             if ( type === "fx" ) {
1513:                 queue.unshift("inprogress");
1514:             }
1515:
1516:             fn.call(elem, function() {
1517:                 jQuery.dequeue(elem, type);
1518:             });
1519:         }
1520:     }
1521: });
1522:
1523: jQuery.fn.extend({
1524:     queue: function( type, data ) {
1525:         ///    <summary>
1526:         ///        1: queue() - Returns a reference to the first element's queue (which is an array of functions).
1527:         ///        2: queue(callback) - Adds a new function, to be executed, onto the end of the queue of all matched elements.
1528:         ///        3: queue(queue) - Replaces the queue of all matched element with this new queue (the array of functions).
1529:         ///    </summary>
1530:         ///    <param name="type" type="Function">The function to add to the queue.</param>
1531:         ///    <returns type="jQuery" />
1532:
1533:         if ( typeof type !== "string" ) {
1534:             data = type;
1535:             type = "fx";
1536:         }
1537:
1538:         if ( data === undefined ) {
1539:             return jQuery.queue( this[0], type );
1540:         }
1541:         return this.each(function( i, elem ) {
1542:             var queue = jQuery.queue( this, type, data );
1543:
1544:             if ( type === "fx" && queue[0] !== "inprogress" ) {
1545:                 jQuery.dequeue( this, type );
1546:             }
1547:         });
1548:     },
1549:     dequeue: function( type ) {
1550:         ///    <summary>
1551:         ///        Removes a queued function from the front of the queue and executes it.
1552:         ///    </summary>
1553:         ///    <param name="type" type="String" optional="true">The type of queue to access.</param>
1554:         ///    <returns type="jQuery" />
1555:
1556:         return this.each(function() {
1557:             jQuery.dequeue( this, type );
1558:         });
1559:     },
1560:
1561:     // Based off of the plugin by Clint Helfers, with permission.
1562:     // http://blindsignals.com/index.php/2009/07/jquery-delay/
1563:     delay: function( time, type ) {
1564:         ///    <summary>
1565:         ///        Set a timer to delay execution of subsequent items in the queue.
1566:         ///    </summary>
1567:         ///    <param name="time" type="Number">
1568:         ///        An integer indicating the number of milliseconds to delay execution of the next item in the queue.
1569:         ///    </param>
1570:         ///    <param name="type" type="String">
1571:         ///        A string containing the name of the queue. Defaults to fx, the standard effects queue.
1572:         ///    </param>
1573:         ///    <returns type="jQuery" />
1574:
1575:         time = jQuery.fx ? jQuery.fx.speeds[time] || time : time;
1576:         type = type || "fx";
1577:
1578:         return this.queue( type, function() {
1579:             var elem = this;
1580:             setTimeout(function() {
1581:                 jQuery.dequeue( elem, type );
1582:             }, time );
1583:         });
1584:     },
1585:
1586:     clearQueue: function( type ) {
1587:         ///    <summary>
1588:         ///        Remove from the queue all items that have not yet been run.
1589:         ///    </summary>
1590:         ///    <param name="type" type="String" optional="true">
1591:         ///        A string containing the name of the queue. Defaults to fx, the standard effects queue.
1592:         ///    </param>
1593:         ///    <returns type="jQuery" />
1594:
1595:         return this.queue( type || "fx", [] );
1596:     }
1597: });
1598: var rclass = /[\n\t]/g,
1599:     rspace = /\s+/,
1600:     rreturn = /\r/g,
1601:     rspecialurl = /href|src|style/,
1602:     rtype = /(button|input)/i,
1603:     rfocusable = /(button|input|object|select|textarea)/i,
1604:     rclickable = /^(a|area)$/i,
1605:     rradiocheck = /radio|checkbox/;
1606:
1607: jQuery.fn.extend({
1608:     attr: function( name, value ) {
1609:         ///    <summary>
1610:         ///        Set a single property to a computed value, on all matched elements.
1611:         ///        Instead of a value, a function is provided, that computes the value.
1612:         ///        Part of DOM/Attributes
1613:         ///    </summary>
1614:         ///    <returns type="jQuery" />
1615:         ///    <param name="name" type="String">
1616:         ///        The name of the property to set.
1617:         ///    </param>
1618:         ///    <param name="value" type="Function">
1619:         ///        A function returning the value to set.
1620:         ///    </param>
1621:
1622:         return access( this, name, value, true, jQuery.attr );
1623:     },
1624:
1625:     removeAttr: function( name, fn ) {
1626:         ///    <summary>
1627:         ///        Remove an attribute from each of the matched elements.
1628:         ///        Part of DOM/Attributes
1629:         ///    </summary>
1630:         ///    <param name="name" type="String">
1631:         ///        An attribute to remove.
1632:         ///    </param>
1633:         ///    <returns type="jQuery" />
1634:
1635:         return this.each(function(){
1636:             jQuery.attr( this, name, "" );
1637:             if ( this.nodeType === 1 ) {
1638:                 this.removeAttribute( name );
1639:             }
1640:         });
1641:     },
1642:
1643:     addClass: function( value ) {
1644:         ///    <summary>
1645:         ///        Adds the specified class(es) to each of the set of matched elements.
1646:         ///        Part of DOM/Attributes
1647:         ///    </summary>
1648:         ///    <param name="value" type="String">
1649:         ///        One or more class names to be added to the class attribute of each matched element.
1650:         ///    </param>
1651:         ///    <returns type="jQuery" />
1652:
1653:         if ( jQuery.isFunction(value) ) {
1654:             return this.each(function(i) {
1655:                 var self = jQuery(this);
1656:                 self.addClass( value.call(this, i, self.attr("class")) );
1657:             });
1658:         }
1659:
1660:         if ( value && typeof value === "string" ) {
1661:             var classNames = (value || "").split( rspace );
1662:
1663:             for ( var i = 0, l = this.length; i < l; i++ ) {
1664:                 var elem = this[i];
1665:
1666:                 if ( elem.nodeType === 1 ) {
1667:                     if ( !elem.className ) {
1668:                         elem.className = value;
1669:
1670:                     } else {
1671:                         var className = " " + elem.className + " ";
1672:                         for ( var c = 0, cl = classNames.length; c < cl; c++ ) {
1673:                             if ( className.indexOf( " " + classNames[c] + " " ) < 0 ) {
1674:                                 elem.className += " " + classNames[c];
1675:                             }
1676:                         }
1677:                     }
1678:                 }
1679:             }
1680:         }
1681:
1682:         return this;
1683:     },
1684:
1685:     removeClass: function( value ) {
1686:         ///    <summary>
1687:         ///        Removes all or the specified class(es) from the set of matched elements.
1688:         ///        Part of DOM/Attributes
1689:         ///    </summary>
1690:         ///    <param name="value" type="String" optional="true">
1691:         ///        (Optional) A class name to be removed from the class attribute of each matched element.
1692:         ///    </param>
1693:         ///    <returns type="jQuery" />
1694:
1695:         if ( jQuery.isFunction(value) ) {
1696:             return this.each(function(i) {
1697:                 var self = jQuery(this);
1698:                 self.removeClass( value.call(this, i, self.attr("class")) );
1699:             });
1700:         }
1701:
1702:         if ( (value && typeof value === "string") || value === undefined ) {
1703:             var classNames = (value || "").split(rspace);
1704:
1705:             for ( var i = 0, l = this.length; i < l; i++ ) {
1706:                 var elem = this[i];
1707:
1708:                 if ( elem.nodeType === 1 && elem.className ) {
1709:                     if ( value ) {
1710:                         var className = (" " + elem.className + " ").replace(rclass, " ");
1711:                         for ( var c = 0, cl = classNames.length; c < cl; c++ ) {
1712:                             className = className.replace(" " + classNames[c] + " ", " ");
1713:                         }
1714:                         elem.className = className.substring(1, className.length - 1);
1715:
1716:                     } else {
1717:                         elem.className = "";
1718:                     }
1719:                 }
1720:             }
1721:         }
1722:
1723:         return this;
1724:     },
1725:
1726:     toggleClass: function( value, stateVal ) {
1727:         ///    <summary>
1728:         ///        Add or remove a class from each element in the set of matched elements, depending
1729:         ///        on either the class's presence or the value of the switch argument.
1730:         ///    </summary>
1731:         ///    <param name="value" type="Object">
1732:         ///        A class name to be toggled for each element in the matched set.
1733:         ///    </param>
1734:         ///    <param name="stateVal" type="Object">
1735:         ///        A boolean value to determine whether the class should be added or removed.
1736:         ///    </param>
1737:         ///    <returns type="jQuery" />
1738:
1739:         var type = typeof value, isBool = typeof stateVal === "boolean";
1740:
1741:         if ( jQuery.isFunction( value ) ) {
1742:             return this.each(function(i) {
1743:                 var self = jQuery(this);
1744:                 self.toggleClass( value.call(this, i, self.attr("class"), stateVal), stateVal );
1745:             });
1746:         }
1747:
1748:         return this.each(function() {
1749:             if ( type === "string" ) {
1750:                 // toggle individual class names
1751:                 var className, i = 0, self = jQuery(this),
1752:                     state = stateVal,
1753:                     classNames = value.split( rspace );
1754:
1755:                 while ( (className = classNames[ i++ ]) ) {
1756:                     // check each className given, space seperated list
1757:                     state = isBool ? state : !self.hasClass( className );
1758:                     self[ state ? "addClass" : "removeClass" ]( className );
1759:                 }
1760:
1761:             } else if ( type === "undefined" || type === "boolean" ) {
1762:                 if ( this.className ) {
1763:                     // store className if set
1764:                     jQuery.data( this, "__className__", this.className );
1765:                 }
1766:
1767:                 // toggle whole className
1768:                 this.className = this.className || value === false ? "" : jQuery.data( this, "__className__" ) || "";
1769:             }
1770:         });
1771:     },
1772:
1773:     hasClass: function( selector ) {
1774:         ///    <summary>
1775:         ///        Checks the current selection against a class and returns whether at least one selection has a given class.
1776:         ///    </summary>
1777:         ///    <param name="selector" type="String">The class to check against</param>
1778:         ///    <returns type="Boolean">True if at least one element in the selection has the class, otherwise false.</returns>
1779:
1780:         var className = " " + selector + " ";
1781:         for ( var i = 0, l = this.length; i < l; i++ ) {
1782:             if ( (" " + this[i].className + " ").replace(rclass, " ").indexOf( className ) > -1 ) {
1783:                 return true;
1784:             }
1785:         }
1786:
1787:         return false;
1788:     },
1789:
1790:     val: function( value ) {
1791:         ///    <summary>
1792:         ///        Set the value of every matched element.
1793:         ///        Part of DOM/Attributes
1794:         ///    </summary>
1795:         ///    <returns type="jQuery" />
1796:         ///    <param name="value" type="String">
1797:         ///        A string of text or an array of strings to set as the value property of each
1798:         ///        matched element.
1799:         ///    </param>
1800:
1801:         if ( value === undefined ) {
1802:             var elem = this[0];
1803:
1804:             if ( elem ) {
1805:                 if ( jQuery.nodeName( elem, "option" ) ) {
1806:                     return (elem.attributes.value || {}).specified ? elem.value : elem.text;
1807:                 }
1808:
1809:                 // We need to handle select boxes special
1810:                 if ( jQuery.nodeName( elem, "select" ) ) {
1811:                     var index = elem.selectedIndex,
1812:                         values = [],
1813:                         options = elem.options,
1814:                         one = elem.type === "select-one";
1815:
1816:                     // Nothing was selected
1817:                     if ( index < 0 ) {
1818:                         return null;
1819:                     }
1820:
1821:                     // Loop through all the selected options
1822:                     for ( var i = one ? index : 0, max = one ? index + 1 : options.length; i < max; i++ ) {
1823:                         var option = options[ i ];
1824:
1825:                         if ( option.selected ) {
1826:                             // Get the specifc value for the option
1827:                             value = jQuery(option).val();
1828:
1829:                             // We don't need an array for one selects
1830:                             if ( one ) {
1831:                                 return value;
1832:                             }
1833:
1834:                             // Multi-Selects return an array
1835:                             values.push( value );
1836:                         }
1837:                     }
1838:
1839:                     return values;
1840:                 }
1841:
1842:                 // Handle the case where in Webkit "" is returned instead of "on" if a value isn't specified
1843:                 if ( rradiocheck.test( elem.type ) && !jQuery.support.checkOn ) {
1844:                     return elem.getAttribute("value") === null ? "on" : elem.value;
1845:                 }
1846:                 
1847:
1848:                 // Everything else, we just grab the value
1849:                 return (elem.value || "").replace(rreturn, "");
1850:
1851:             }
1852:
1853:             return undefined;
1854:         }
1855:
1856:         var isFunction = jQuery.isFunction(value);
1857:
1858:         return this.each(function(i) {
1859:             var self = jQuery(this), val = value;
1860:
1861:             if ( this.nodeType !== 1 ) {
1862:                 return;
1863:             }
1864:
1865:             if ( isFunction ) {
1866:                 val = value.call(this, i, self.val());
1867:             }
1868:
1869:             // Typecast each time if the value is a Function and the appended
1870:             // value is therefore different each time.
1871:             if ( typeof val === "number" ) {
1872:                 val += "";
1873:             }
1874:
1875:             if ( jQuery.isArray(val) && rradiocheck.test( this.type ) ) {
1876:                 this.checked = jQuery.inArray( self.val(), val ) >= 0;
1877:
1878:             } else if ( jQuery.nodeName( this, "select" ) ) {
1879:                 var values = jQuery.makeArray(val);
1880:
1881:                 jQuery( "option", this ).each(function() {
1882:                     this.selected = jQuery.inArray( jQuery(this).val(), values ) >= 0;
1883:                 });
1884:
1885:                 if ( !values.length ) {
1886:                     this.selectedIndex = -1;
1887:                 }
1888:
1889:             } else {
1890:                 this.value = val;
1891:             }
1892:         });
1893:     }
1894: });
1895:
1896: jQuery.extend({
1897:     attrFn: {
1898:         val: true,
1899:         css: true,
1900:         html: true,
1901:         text: true,
1902:         data: true,
1903:         width: true,
1904:         height: true,
1905:         offset: true
1906:     },
1907:         
1908:     attr: function( elem, name, value, pass ) {
1909:         ///    <summary>
1910:         ///        This method is internal.
1911:         ///    </summary>
1912:         ///    <private />
1913:
1914:         // don't set attributes on text and comment nodes
1915:         if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 ) {
1916:             return undefined;
1917:         }
1918:
1919:         if ( pass && name in jQuery.attrFn ) {
1920:             return jQuery(elem)[name](value);
1921:         }
1922:
1923:         var notxml = elem.nodeType !== 1 || !jQuery.isXMLDoc( elem ),
1924:             // Whether we are setting (or getting)
1925:             set = value !== undefined;
1926:
1927:         // Try to normalize/fix the name
1928:         name = notxml && jQuery.props[ name ] || name;
1929:
1930:         // Only do all the following if this is a node (faster for style)
1931:         if ( elem.nodeType === 1 ) {
1932:             // These attributes require special treatment
1933:             var special = rspecialurl.test( name );
1934:
1935:             // Safari mis-reports the default selected property of an option
1936:             // Accessing the parent's selectedIndex property fixes it
1937:             if ( name === "selected" && !jQuery.support.optSelected ) {
1938:                 var parent = elem.parentNode;
1939:                 if ( parent ) {
1940:                     parent.selectedIndex;
1941:     
1942:                     // Make sure that it also works with optgroups, see #5701
1943:                     if ( parent.parentNode ) {
1944:                         parent.parentNode.selectedIndex;
1945:                     }
1946:                 }
1947:             }
1948:
1949:             // If applicable, access the attribute via the DOM 0 way
1950:             if ( name in elem && notxml && !special ) {
1951:                 if ( set ) {
1952:                     // We can't allow the type property to be changed (since it causes problems in IE)
1953:                     if ( name === "type" && rtype.test( elem.nodeName ) && elem.parentNode ) {
1954:                         jQuery.error( "type property can't be changed" );
1955:                     }
1956:
1957:                     elem[ name ] = value;
1958:                 }
1959:
1960:                 // browsers index elements by id/name on forms, give priority to attributes.
1961:                 if ( jQuery.nodeName( elem, "form" ) && elem.getAttributeNode(name) ) {
1962:                     return elem.getAttributeNode( name ).nodeValue;
1963:                 }
1964:
1965:                 // elem.tabIndex doesn't always return the correct value when it hasn't been explicitly set
1966:                 // http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/
1967:                 if ( name === "tabIndex" ) {
1968:                     var attributeNode = elem.getAttributeNode( "tabIndex" );
1969:
1970:                     return attributeNode && attributeNode.specified ?
1971:                         attributeNode.value :
1972:                         rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ?
1973:                             0 :
1974:                             undefined;
1975:                 }
1976:
1977:                 return elem[ name ];
1978:             }
1979:
1980:             if ( !jQuery.support.style && notxml && name === "style" ) {
1981:                 if ( set ) {
1982:                     elem.style.cssText = "" + value;
1983:                 }
1984:
1985:                 return elem.style.cssText;
1986:             }
1987:
1988:             if ( set ) {
1989:                 // convert the value to a string (all browsers do this but IE) see #1070
1990:                 elem.setAttribute( name, "" + value );
1991:             }
1992:
1993:             var attr = !jQuery.support.hrefNormalized && notxml && special ?
1994:                     // Some attributes require a special call on IE
1995:                     elem.getAttribute( name, 2 ) :
1996:                     elem.getAttribute( name );
1997:
1998:             // Non-existent attributes return null, we normalize to undefined
1999:             return attr === null ? undefined : attr;
2000:         }
2001:
2002:         // elem is actually elem.style ... set the style
2003:         // Using attr for specific style information is now deprecated. Use style insead.
2004:         return jQuery.style( elem, name, value );
2005:     }
2006: });
2007: var fcleanup = function( nm ) {
2008:     return nm.replace(/[^\w\s\.\|`]/g, function( ch ) {
2009:         return "\\" + ch;
2010:     });
2011: };
2012:
2013: /*
2014: * A number of helper functions used for managing events.
2015: * Many of the ideas behind this code originated from
2016: * Dean Edwards' addEvent library.
2017: */
2018: jQuery.event = {
2019:
2020:     // Bind an event to an element
2021:     // Original by Dean Edwards
2022:     add: function( elem, types, handler, data ) {
2023:         ///    <summary>
2024:         ///        This method is internal.
2025:         ///    </summary>
2026:         ///    <private />
2027:
2028:         if ( elem.nodeType === 3 || elem.nodeType === 8 ) {
2029:             return;
2030:         }
2031:
2032:         // For whatever reason, IE has trouble passing the window object
2033:         // around, causing it to be cloned in the process
2034:         if ( elem.setInterval && ( elem !== window && !elem.frameElement ) ) {
2035:             elem = window;
2036:         }
2037:
2038:         // Make sure that the function being executed has a unique ID
2039:         if ( !handler.guid ) {
2040:             handler.guid = jQuery.guid++;
2041:         }
2042:
2043:         // if data is passed, bind to handler
2044:         if ( data !== undefined ) {
2045:             // Create temporary function pointer to original handler
2046:             var fn = handler;
2047:
2048:             // Create unique handler function, wrapped around original handler
2049:             handler = jQuery.proxy( fn );
2050:
2051:             // Store data in unique handler
2052:             handler.data = data;
2053:         }
2054:
2055:         // Init the element's event structure
2056:         var events = jQuery.data( elem, "events" ) || jQuery.data( elem, "events", {} ),
2057:             handle = jQuery.data( elem, "handle" ), eventHandle;
2058:
2059:         if ( !handle ) {
2060:             eventHandle = function() {
2061:                 // Handle the second event of a trigger and when
2062:                 // an event is called after a page has unloaded
2063:                 return typeof jQuery !== "undefined" && !jQuery.event.triggered ?
2064:                     jQuery.event.handle.apply( eventHandle.elem, arguments ) :
2065:                     undefined;
2066:             };
2067:
2068:             handle = jQuery.data( elem, "handle", eventHandle );
2069:         }
2070:
2071:         // If no handle is found then we must be trying to bind to one of the
2072:         // banned noData elements
2073:         if ( !handle ) {
2074:             return;
2075:         }
2076:
2077:         // Add elem as a property of the handle function
2078:         // This is to prevent a memory leak with non-native
2079:         // event in IE.
2080:         handle.elem = elem;
2081:
2082:         // Handle multiple events separated by a space
2083:         // jQuery(...).bind("mouseover mouseout", fn);
2084:         types = types.split( /\s+/ );
2085:
2086:         var type, i = 0;
2087:
2088:         while ( (type = types[ i++ ]) ) {
2089:             // Namespaced event handlers
2090:             var namespaces = type.split(".");
2091:             type = namespaces.shift();
2092:
2093:             if ( i > 1 ) {
2094:                 handler = jQuery.proxy( handler );
2095:
2096:                 if ( data !== undefined ) {
2097:                     handler.data = data;
2098:                 }
2099:             }
2100:
2101:             handler.type = namespaces.slice(0).sort().join(".");
2102:
2103:             // Get the current list of functions bound to this event
2104:             var handlers = events[ type ],
2105:                 special = this.special[ type ] || {};
2106:
2107:             // Init the event handler queue
2108:             if ( !handlers ) {
2109:                 handlers = events[ type ] = {};
2110:
2111:                 // Check for a special event handler
2112:                 // Only use addEventListener/attachEvent if the special
2113:                 // events handler returns false
2114:                 if ( !special.setup || special.setup.call( elem, data, namespaces, handler) === false ) {
2115:                     // Bind the global event handler to the element
2116:                     if ( elem.addEventListener ) {
2117:                         elem.addEventListener( type, handle, false );
2118:                     } else if ( elem.attachEvent ) {
2119:                         elem.attachEvent( "on" + type, handle );
2120:                     }
2121:                 }
2122:             }
2123:             
2124:             if ( special.add ) {
2125:                 var modifiedHandler = special.add.call( elem, handler, data, namespaces, handlers );
2126:                 if ( modifiedHandler && jQuery.isFunction( modifiedHandler ) ) {
2127:                     modifiedHandler.guid = modifiedHandler.guid || handler.guid;
2128:                     modifiedHandler.data = modifiedHandler.data || handler.data;
2129:                     modifiedHandler.type = modifiedHandler.type || handler.type;
2130:                     handler = modifiedHandler;
2131:                 }
2132:             }
2133:             
2134:             // Add the function to the element's handler list
2135:             handlers[ handler.guid ] = handler;
2136:
2137:             // Keep track of which events have been used, for global triggering
2138:             this.global[ type ] = true;
2139:         }
2140:
2141:         // Nullify elem to prevent memory leaks in IE
2142:         elem = null;
2143:     },
2144:
2145:     global: {},
2146:
2147:     // Detach an event or set of events from an element
2148:     remove: function( elem, types, handler ) {
2149:         ///    <summary>
2150:         ///        This method is internal.
2151:         ///    </summary>
2152:         ///    <private />
2153:
2154:         // don't do events on text and comment nodes
2155:         if ( elem.nodeType === 3 || elem.nodeType === 8 ) {
2156:             return;
2157:         }
2158:
2159:         var events = jQuery.data( elem, "events" ), ret, type, fn;
2160:
2161:         if ( events ) {
2162:             // Unbind all events for the element
2163:             if ( types === undefined || (typeof types === "string" && types.charAt(0) === ".") ) {
2164:                 for ( type in events ) {
2165:                     this.remove( elem, type + (types || "") );
2166:                 }
2167:             } else {
2168:                 // types is actually an event object here
2169:                 if ( types.type ) {
2170:                     handler = types.handler;
2171:                     types = types.type;
2172:                 }
2173:
2174:                 // Handle multiple events separated by a space
2175:                 // jQuery(...).unbind("mouseover mouseout", fn);
2176:                 types = types.split(/\s+/);
2177:                 var i = 0;
2178:                 while ( (type = types[ i++ ]) ) {
2179:                     // Namespaced event handlers
2180:                     var namespaces = type.split(".");
2181:                     type = namespaces.shift();
2182:                     var all = !namespaces.length,
2183:                         cleaned = jQuery.map( namespaces.slice(0).sort(), fcleanup ),
2184:                         namespace = new RegExp("(^|\\.)" + cleaned.join("\\.(?:.*\\.)?") + "(\\.|$)"),
2185:                         special = this.special[ type ] || {};
2186:
2187:                     if ( events[ type ] ) {
2188:                         // remove the given handler for the given type
2189:                         if ( handler ) {
2190:                             fn = events[ type ][ handler.guid ];
2191:                             delete events[ type ][ handler.guid ];
2192:
2193:                         // remove all handlers for the given type
2194:                         } else {
2195:                             for ( var handle in events[ type ] ) {
2196:                                 // Handle the removal of namespaced events
2197:                                 if ( all || namespace.test( events[ type ][ handle ].type ) ) {
2198:                                     delete events[ type ][ handle ];
2199:                                 }
2200:                             }
2201:                         }
2202:
2203:                         if ( special.remove ) {
2204:                             special.remove.call( elem, namespaces, fn);
2205:                         }
2206:
2207:                         // remove generic event handler if no more handlers exist
2208:                         for ( ret in events[ type ] ) {
2209:                             break;
2210:                         }
2211:                         if ( !ret ) {
2212:                             if ( !special.teardown || special.teardown.call( elem, namespaces ) === false ) {
2213:                                 if ( elem.removeEventListener ) {
2214:                                     elem.removeEventListener( type, jQuery.data( elem, "handle" ), false );
2215:                                 } else if ( elem.detachEvent ) {
2216:                                     elem.detachEvent( "on" + type, jQuery.data( elem, "handle" ) );
2217:                                 }
2218:                             }
2219:                             ret = null;
2220:                             delete events[ type ];
2221:                         }
2222:                     }
2223:                 }
2224:             }
2225:
2226:             // Remove the expando if it's no longer used
2227:             for ( ret in events ) {
2228:                 break;
2229:             }
2230:             if ( !ret ) {
2231:                 var handle = jQuery.data( elem, "handle" );
2232:                 if ( handle ) {
2233:                     handle.elem = null;
2234:                 }
2235:                 jQuery.removeData( elem, "events" );
2236:                 jQuery.removeData( elem, "handle" );
2237:             }
2238:         }
2239:     },
2240:
2241:     // bubbling is internal
2242:     trigger: function( event, data, elem /*, bubbling */ ) {
2243:         ///    <summary>
2244:         ///        This method is internal.
2245:         ///    </summary>
2246:         ///    <private />
2247:
2248:         // Event object or event type
2249:         var type = event.type || event,
2250:             bubbling = arguments[3];
2251:
2252:         if ( !bubbling ) {
2253:             event = typeof event === "object" ?
2254:                 // jQuery.Event object
2255:                 event[expando] ? event :
2256:                 // Object literal
2257:                 jQuery.extend( jQuery.Event(type), event ) :
2258:                 // Just the event type (string)
2259:                 jQuery.Event(type);
2260:
2261:             if ( type.indexOf("!") >= 0 ) {
2262:                 event.type = type = type.slice(0, -1);
2263:                 event.exclusive = true;
2264:             }
2265:
2266:             // Handle a global trigger
2267:             if ( !elem ) {
2268:                 // Don't bubble custom events when global (to avoid too much overhead)
2269:                 event.stopPropagation();
2270:
2271:                 // Only trigger if we've ever bound an event for it
2272:                 if ( this.global[ type ] ) {
2273:                     jQuery.each( jQuery.cache, function() {
2274:                         if ( this.events && this.events[type] ) {
2275:                             jQuery.event.trigger( event, data, this.handle.elem );
2276:                         }
2277:                     });
2278:                 }
2279:             }
2280:
2281:             // Handle triggering a single element
2282:
2283:             // don't do events on text and comment nodes
2284:             if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 ) {
2285:                 return undefined;
2286:             }
2287:
2288:             // Clean up in case it is reused
2289:             event.result = undefined;
2290:             event.target = elem;
2291:
2292:             // Clone the incoming data, if any
2293:             data = jQuery.makeArray( data );
2294:             data.unshift( event );
2295:         }
2296:
2297:         event.currentTarget = elem;
2298:
2299:         // Trigger the event, it is assumed that "handle" is a function
2300:         var handle = jQuery.data( elem, "handle" );
2301:         if ( handle ) {
2302:             handle.apply( elem, data );
2303:         }
2304:
2305:         var parent = elem.parentNode || elem.ownerDocument;
2306:
2307:         // Trigger an inline bound script
2308:         try {
2309:             if ( !(elem && elem.nodeName && jQuery.noData[elem.nodeName.toLowerCase()]) ) {
2310:                 if ( elem[ "on" + type ] && elem[ "on" + type ].apply( elem, data ) === false ) {
2311:                     event.result = false;
2312:                 }
2313:             }
2314:
2315:         // prevent IE from throwing an error for some elements with some event types, see #3533
2316:         } catch (e) {}
2317:
2318:         if ( !event.isPropagationStopped() && parent ) {
2319:             jQuery.event.trigger( event, data, parent, true );
2320:
2321:         } else if ( !event.isDefaultPrevented() ) {
2322:             var target = event.target, old,
2323:                 isClick = jQuery.nodeName(target, "a") && type === "click";
2324:
2325:             if ( !isClick && !(target && target.nodeName && jQuery.noData[target.nodeName.toLowerCase()]) ) {
2326:                 try {
2327:                     if ( target[ type ] ) {
2328:                         // Make sure that we don't accidentally re-trigger the onFOO events
2329:                         old = target[ "on" + type ];
2330:
2331:                         if ( old ) {
2332:                             target[ "on" + type ] = null;
2333:                         }
2334:
2335:                         this.triggered = true;
2336:                         target[ type ]();
2337:                     }
2338:
2339:                 // prevent IE from throwing an error for some elements with some event types, see #3533
2340:                 } catch (e) {}
2341:
2342:                 if ( old ) {
2343:                     target[ "on" + type ] = old;
2344:                 }
2345:
2346:                 this.triggered = false;
2347:             }
2348:         }
2349:     },
2350:
2351:     handle: function( event ) {
2352:         ///    <summary>
2353:         ///        This method is internal.
2354:         ///    </summary>
2355:         ///    <private />
2356:
2357:         // returned undefined or false
2358:         var all, handlers;
2359:
2360:         event = arguments[0] = jQuery.event.fix( event || window.event );
2361:         event.currentTarget = this;
2362:
2363:         // Namespaced event handlers
2364:         var namespaces = event.type.split(".");
2365:         event.type = namespaces.shift();
2366:
2367:         // Cache this now, all = true means, any handler
2368:         all = !namespaces.length && !event.exclusive;
2369:
2370:         var namespace = new RegExp("(^|\\.)" + namespaces.slice(0).sort().join("\\.(?:.*\\.)?") + "(\\.|$)");
2371:
2372:         handlers = ( jQuery.data(this, "events") || {} )[ event.type ];
2373:
2374:         for ( var j in handlers ) {
2375:             var handler = handlers[ j ];
2376:
2377:             // Filter the functions by class
2378:             if ( all || namespace.test(handler.type) ) {
2379:                 // Pass in a reference to the handler function itself
2380:                 // So that we can later remove it
2381:                 event.handler = handler;
2382:                 event.data = handler.data;
2383:
2384:                 var ret = handler.apply( this, arguments );
2385:
2386:                 if ( ret !== undefined ) {
2387:                     event.result = ret;
2388:                     if ( ret === false ) {
2389:                         event.preventDefault();
2390:                         event.stopPropagation();
2391:                     }
2392:                 }
2393:
2394:                 if ( event.isImmediatePropagationStopped() ) {
2395:                     break;
2396:                 }
2397:
2398:             }
2399:         }
2400:
2401:         return event.result;
2402:     },
2403:
2404:     props: "altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),
2405:
2406:     fix: function( event ) {
2407:         ///    <summary>
2408:         ///        This method is internal.
2409:         ///    </summary>
2410:         ///    <private />
2411:
2412:         if ( event[ expando ] ) {
2413:             return event;
2414:         }
2415:
2416:         // store a copy of the original event object
2417:         // and "clone" to set read-only properties
2418:         var originalEvent = event;
2419:         event = jQuery.Event( originalEvent );
2420:
2421:         for ( var i = this.props.length, prop; i; ) {
2422:             prop = this.props[ --i ];
2423:             event[ prop ] = originalEvent[ prop ];
2424:         }
2425:
2426:         // Fix target property, if necessary
2427:         if ( !event.target ) {
2428:             event.target = event.srcElement || document; // Fixes #1925 where srcElement might not be defined either
2429:         }
2430:
2431:         // check if target is a textnode (safari)
2432:         if ( event.target.nodeType === 3 ) {
2433:             event.target = event.target.parentNode;
2434:         }
2435:
2436:         // Add relatedTarget, if necessary
2437:         if ( !event.relatedTarget && event.fromElement ) {
2438:             event.relatedTarget = event.fromElement === event.target ? event.toElement : event.fromElement;
2439:         }
2440:
2441:         // Calculate pageX/Y if missing and clientX/Y available
2442:         if ( event.pageX == null && event.clientX != null ) {
2443:             var doc = document.documentElement, body = document.body;
2444:             event.pageX = event.clientX + (doc && doc.scrollLeft || body && body.scrollLeft || 0) - (doc && doc.clientLeft || body && body.clientLeft || 0);
2445:             event.pageY = event.clientY + (doc && doc.scrollTop || body && body.scrollTop || 0) - (doc && doc.clientTop || body && body.clientTop || 0);
2446:         }
2447:
2448:         // Add which for key events
2449:         if ( !event.which && ((event.charCode || event.charCode === 0) ? event.charCode : event.keyCode) ) {
2450:             event.which = event.charCode || event.keyCode;
2451:         }
2452:
2453:         // Add metaKey to non-Mac browsers (use ctrl for PC's and Meta for Macs)
2454:         if ( !event.metaKey && event.ctrlKey ) {
2455:             event.metaKey = event.ctrlKey;
2456:         }
2457:
2458:         // Add which for click: 1 === left; 2 === middle; 3 === right
2459:         // Note: button is not normalized, so don't use it
2460:         if ( !event.which && event.button !== undefined ) {
2461:             event.which = (event.button & 1 ? 1 : ( event.button & 2 ? 3 : ( event.button & 4 ? 2 : 0 ) ));
2462:         }
2463:
2464:         return event;
2465:     },
2466:
2467:     // Deprecated, use jQuery.guid instead
2468:     guid: 1E8,
2469:
2470:     // Deprecated, use jQuery.proxy instead
2471:     proxy: jQuery.proxy,
2472:
2473:     special: {
2474:         ready: {
2475:             // Make sure the ready event is setup
2476:             setup: jQuery.bindReady,
2477:             teardown: jQuery.noop
2478:         },
2479:
2480:         live: {
2481:             add: function( proxy, data, namespaces, live ) {
2482:                 jQuery.extend( proxy, data || {} );
2483:
2484:                 proxy.guid += data.selector + data.live;
2485:                 data.liveProxy = proxy;
2486:
2487:                 jQuery.event.add( this, data.live, liveHandler, data );
2488:                 
2489:             },
2490:
2491:             remove: function( namespaces ) {
2492:                 if ( namespaces.length ) {
2493:                     var remove = 0, name = new RegExp("(^|\\.)" + namespaces[0] + "(\\.|$)");
2494:
2495:                     jQuery.each( (jQuery.data(this, "events").live || {}), function() {
2496:                         if ( name.test(this.type) ) {
2497:                             remove++;
2498:                         }
2499:                     });
2500:
2501:                     if ( remove < 1 ) {
2502:                         jQuery.event.remove( this, namespaces[0], liveHandler );
2503:                     }
2504:                 }
2505:             },
2506:             special: {}
2507:         },
2508:         beforeunload: {
2509:             setup: function( data, namespaces, fn ) {
2510:                 // We only want to do this special case on windows
2511:                 if ( this.setInterval ) {
2512:                     this.onbeforeunload = fn;
2513:                 }
2514:
2515:                 return false;
2516:             },
2517:             teardown: function( namespaces, fn ) {
2518:                 if ( this.onbeforeunload === fn ) {
2519:                     this.onbeforeunload = null;
2520:                 }
2521:             }
2522:         }
2523:     }
2524: };
2525:
2526: jQuery.Event = function( src ) {
2527:     // Allow instantiation without the 'new' keyword
2528:     if ( !this.preventDefault ) {
2529:         return new jQuery.Event( src );
2530:     }
2531:
2532:     // Event object
2533:     if ( src && src.type ) {
2534:         this.originalEvent = src;
2535:         this.type = src.type;
2536:     // Event type
2537:     } else {
2538:         this.type = src;
2539:     }
2540:
2541:     // timeStamp is buggy for some events on Firefox(#3843)
2542:     // So we won't rely on the native value
2543:     this.timeStamp = now();
2544:
2545:     // Mark it as fixed
2546:     this[ expando ] = true;
2547: };
2548:
2549: function returnFalse() {
2550:     return false;
2551: }
2552: function returnTrue() {
2553:     return true;
2554: }
2555:
2556: // jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding
2557: // http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html
2558: jQuery.Event.prototype = {
2559:     preventDefault: function() {
2560:         this.isDefaultPrevented = returnTrue;
2561:
2562:         var e = this.originalEvent;
2563:         if ( !e ) {
2564:             return;
2565:         }
2566:         
2567:         // if preventDefault exists run it on the original event
2568:         if ( e.preventDefault ) {
2569:             e.preventDefault();
2570:         }
2571:         // otherwise set the returnValue property of the original event to false (IE)
2572:         e.returnValue = false;
2573:     },
2574:     stopPropagation: function() {
2575:         this.isPropagationStopped = returnTrue;
2576:
2577:         var e = this.originalEvent;
2578:         if ( !e ) {
2579:             return;
2580:         }
2581:         // if stopPropagation exists run it on the original event
2582:         if ( e.stopPropagation ) {
2583:             e.stopPropagation();
2584:         }
2585:         // otherwise set the cancelBubble property of the original event to true (IE)
2586:         e.cancelBubble = true;
2587:     },
2588:     stopImmediatePropagation: function() {
2589:         this.isImmediatePropagationStopped = returnTrue;
2590:         this.stopPropagation();
2591:     },
2592:     isDefaultPrevented: returnFalse,
2593:     isPropagationStopped: returnFalse,
2594:     isImmediatePropagationStopped: returnFalse
2595: };
2596:
2597: // Checks if an event happened on an element within another element
2598: // Used in jQuery.event.special.mouseenter and mouseleave handlers
2599: var withinElement = function( event ) {
2600:     // Check if mouse(over|out) are still within the same parent element
2601:     var parent = event.relatedTarget;
2602:
2603:     // Traverse up the tree
2604:     while ( parent && parent !== this ) {
2605:         // Firefox sometimes assigns relatedTarget a XUL element
2606:         // which we cannot access the parentNode property of
2607:         try {
2608:             parent = parent.parentNode;
2609:
2610:         // assuming we've left the element since we most likely mousedover a xul element
2611:         } catch(e) {
2612:             break;
2613:         }
2614:     }
2615:
2616:     if ( parent !== this ) {
2617:         // set the correct event type
2618:         event.type = event.data;
2619:
2620:         // handle event if we actually just moused on to a non sub-element
2621:         jQuery.event.handle.apply( this, arguments );
2622:     }
2623:
2624: },
2625:
2626: // In case of event delegation, we only need to rename the event.type,
2627: // liveHandler will take care of the rest.
2628: delegate = function( event ) {
2629:     event.type = event.data;
2630:     jQuery.event.handle.apply( this, arguments );
2631: };
2632:
2633: // Create mouseenter and mouseleave events
2634: jQuery.each({
2635:     mouseenter: "mouseover",
2636:     mouseleave: "mouseout"
2637: }, function( orig, fix ) {
2638:     jQuery.event.special[ orig ] = {
2639:         setup: function( data ) {
2640:             jQuery.event.add( this, fix, data && data.selector ? delegate : withinElement, orig );
2641:         },
2642:         teardown: function( data ) {
2643:             jQuery.event.remove( this, fix, data && data.selector ? delegate : withinElement );
2644:         }
2645:     };
2646: });
2647:
2648: // submit delegation
2649: if ( !jQuery.support.submitBubbles ) {
2650:
2651: jQuery.event.special.submit = {
2652:     setup: function( data, namespaces, fn ) {
2653:         if ( this.nodeName.toLowerCase() !== "form" ) {
2654:             jQuery.event.add(this, "click.specialSubmit." + fn.guid, function( e ) {
2655:                 var elem = e.target, type = elem.type;
2656:
2657:                 if ( (type === "submit" || type === "image") && jQuery( elem ).closest("form").length ) {
2658:                     return trigger( "submit", this, arguments );
2659:                 }
2660:             });
2661:     
2662:             jQuery.event.add(this, "keypress.specialSubmit." + fn.guid, function( e ) {
2663:                 var elem = e.target, type = elem.type;
2664:
2665:                 if ( (type === "text" || type === "password") && jQuery( elem ).closest("form").length && e.keyCode === 13 ) {
2666:                     return trigger( "submit", this, arguments );
2667:                 }
2668:             });
2669:
2670:         } else {
2671:             return false;
2672:         }
2673:     },
2674:
2675:     remove: function( namespaces, fn ) {
2676:         jQuery.event.remove( this, "click.specialSubmit" + (fn ? "."+fn.guid : "") );
2677:         jQuery.event.remove( this, "keypress.specialSubmit" + (fn ? "."+fn.guid : "") );
2678:     }
2679: };
2680:
2681: }
2682:
2683: // change delegation, happens here so we have bind.
2684: if ( !jQuery.support.changeBubbles ) {
2685:
2686: var formElems = /textarea|input|select/i;
2687:
2688: function getVal( elem ) {
2689:     var type = elem.type, val = elem.value;
2690:
2691:     if ( type === "radio" || type === "checkbox" ) {
2692:         val = elem.checked;
2693:
2694:     } else if ( type === "select-multiple" ) {
2695:         val = elem.selectedIndex > -1 ?
2696:             jQuery.map( elem.options, function( elem ) {
2697:                 return elem.selected;
2698:             }).join("-") :
2699:             "";
2700:
2701:     } else if ( elem.nodeName.toLowerCase() === "select" ) {
2702:         val = elem.selectedIndex;
2703:     }
2704:
2705:     return val;
2706: }
2707:
2708: function testChange( e ) {
2709:         var elem = e.target, data, val;
2710:
2711:         if ( !formElems.test( elem.nodeName ) || elem.readOnly ) {
2712:             return;
2713:         }
2714:
2715:         data = jQuery.data( elem, "_change_data" );
2716:         val = getVal(elem);
2717:
2718:         // the current data will be also retrieved by beforeactivate
2719:         if ( e.type !== "focusout" || elem.type !== "radio" ) {
2720:             jQuery.data( elem, "_change_data", val );
2721:         }
2722:         
2723:         if ( data === undefined || val === data ) {
2724:             return;
2725:         }
2726:
2727:         if ( data != null || val ) {
2728:             e.type = "change";
2729:             return jQuery.event.trigger( e, arguments[1], elem );
2730:         }
2731: }
2732:
2733: jQuery.event.special.change = {
2734:     filters: {
2735:         focusout: testChange,
2736:
2737:         click: function( e ) {
2738:             var elem = e.target, type = elem.type;
2739:
2740:             if ( type === "radio" || type === "checkbox" || elem.nodeName.toLowerCase() === "select" ) {
2741:                 return testChange.call( this, e );
2742:             }
2743:         },
2744:
2745:         // Change has to be called before submit
2746:         // Keydown will be called before keypress, which is used in submit-event delegation
2747:         keydown: function( e ) {
2748:             var elem = e.target, type = elem.type;
2749:
2750:             if ( (e.keyCode === 13 && elem.nodeName.toLowerCase() !== "textarea") ||
2751:                 (e.keyCode === 32 && (type === "checkbox" || type === "radio")) ||
2752:                 type === "select-multiple" ) {
2753:                 return testChange.call( this, e );
2754:             }
2755:         },
2756:
2757:         // Beforeactivate happens also before the previous element is blurred
2758:         // with this event you can't trigger a change event, but you can store
2759:         // information/focus[in] is not needed anymore
2760:         beforeactivate: function( e ) {
2761:             var elem = e.target;
2762:
2763:             if ( elem.nodeName.toLowerCase() === "input" && elem.type === "radio" ) {
2764:                 jQuery.data( elem, "_change_data", getVal(elem) );
2765:             }
2766:         }
2767:     },
2768:     setup: function( data, namespaces, fn ) {
2769:         for ( var type in changeFilters ) {
2770:             jQuery.event.add( this, type + ".specialChange." + fn.guid, changeFilters[type] );
2771:         }
2772:
2773:         return formElems.test( this.nodeName );
2774:     },
2775:     remove: function( namespaces, fn ) {
2776:         for ( var type in changeFilters ) {
2777:             jQuery.event.remove( this, type + ".specialChange" + (fn ? "."+fn.guid : ""), changeFilters[type] );
2778:         }
2779:
2780:         return formElems.test( this.nodeName );
2781:     }
2782: };
2783:
2784: var changeFilters = jQuery.event.special.change.filters;
2785:
2786: }
2787:
2788: function trigger( type, elem, args ) {
2789:     args[0].type = type;
2790:     return jQuery.event.handle.apply( elem, args );
2791: }
2792:
2793: // Create "bubbling" focus and blur events
2794: if ( document.addEventListener ) {
2795:     jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) {
2796:         jQuery.event.special[ fix ] = {
2797:             setup: function() {
2798:                 ///    <summary>
2799:                 ///        This method is internal.
2800:                 ///    </summary>
2801:                 ///    <private />
2802:
2803:                 this.addEventListener( orig, handler, true );
2804:             },
2805:             teardown: function() {
2806:                 ///    <summary>
2807:                 ///        This method is internal.
2808:                 ///    </summary>
2809:                 ///    <private />
2810:
2811:                 this.removeEventListener( orig, handler, true );
2812:             }
2813:         };
2814:
2815:         function handler( e ) {
2816:             e = jQuery.event.fix( e );
2817:             e.type = fix;
2818:             return jQuery.event.handle.call( this, e );
2819:         }
2820:     });
2821: }
2822:
2823: //    jQuery.each(["bind", "one"], function( i, name ) {
2824: //        jQuery.fn[ name ] = function( type, data, fn ) {
2825: //            // Handle object literals
2826: //            if ( typeof type === "object" ) {
2827: //                for ( var key in type ) {
2828: //                    this[ name ](key, data, type[key], fn);
2829: //                }
2830: //                return this;
2831: //            }
2832: //            
2833: //            if ( jQuery.isFunction( data ) ) {
2834: //                fn = data;
2835: //                data = undefined;
2836: //            }
2837: //
2838: //            var handler = name === "one" ? jQuery.proxy( fn, function( event ) {
2839: //                jQuery( this ).unbind( event, handler );
2840: //                return fn.apply( this, arguments );
2841: //            }) : fn;
2842: //
2843: //            return type === "unload" && name !== "one" ?
2844: //                this.one( type, data, fn ) :
2845: //                this.each(function() {
2846: //                    jQuery.event.add( this, type, handler, data );
2847: //                });
2848: //        };
2849: //    });
2850:
2851: jQuery.fn[ "bind" ] = function( type, data, fn ) {
2852:     ///    <summary>
2853:     ///        Binds a handler to one or more events for each matched element. Can also bind custom events.
2854:     ///    </summary>
2855:     ///    <param name="type" type="String">One or more event types separated by a space. Built-in event type values are: blur, focus, load, resize, scroll, unload, click, dblclick, mousedown, mouseup, mousemove, mouseover, mouseout, mouseenter, mouseleave, change, select, submit, keydown, keypress, keyup, error .</param>
2856:     ///    <param name="data" optional="true" type="Object">Additional data passed to the event handler as event.data</param>
2857:     ///    <param name="fn" type="Function">A function to bind to the event on each of the set of matched elements. function callback(eventObject) such that this corresponds to the dom element.</param>
2858:
2859:     // Handle object literals
2860:     if ( typeof type === "object" ) {
2861:         for ( var key in type ) {
2862:             this[ "bind" ](key, data, type[key], fn);
2863:         }
2864:         return this;
2865:     }
2866:     
2867:     if ( jQuery.isFunction( data ) ) {
2868:         fn = data;
2869:         data = undefined;
2870:     }
2871:
2872:     var handler = "bind" === "one" ? jQuery.proxy( fn, function( event ) {
2873:         jQuery( this ).unbind( event, handler );
2874:         return fn.apply( this, arguments );
2875:     }) : fn;
2876:
2877:     return type === "unload" && "bind" !== "one" ?
2878:         this.one( type, data, fn ) :
2879:         this.each(function() {
2880:             jQuery.event.add( this, type, handler, data );
2881:         });
2882: };
2883:
2884: jQuery.fn[ "one" ] = function( type, data, fn ) {
2885:     ///    <summary>
2886:     ///        Binds a handler to one or more events to be executed exactly once for each matched element.
2887:     ///    </summary>
2888:     ///    <param name="type" type="String">One or more event types separated by a space. Built-in event type values are: blur, focus, load, resize, scroll, unload, click, dblclick, mousedown, mouseup, mousemove, mouseover, mouseout, mouseenter, mouseleave, change, select, submit, keydown, keypress, keyup, error .</param>
2889:     ///    <param name="data" optional="true" type="Object">Additional data passed to the event handler as event.data</param>
2890:     ///    <param name="fn" type="Function">A function to bind to the event on each of the set of matched elements. function callback(eventObject) such that this corresponds to the dom element.</param>
2891:
2892:     // Handle object literals
2893:     if ( typeof type === "object" ) {
2894:         for ( var key in type ) {
2895:             this[ "one" ](key, data, type[key], fn);
2896:         }
2897:         return this;
2898:     }
2899:     
2900:     if ( jQuery.isFunction( data ) ) {
2901:         fn = data;
2902:         data = undefined;
2903:     }
2904:
2905:     var handler = "one" === "one" ? jQuery.proxy( fn, function( event ) {
2906:         jQuery( this ).unbind( event, handler );
2907:         return fn.apply( this, arguments );
2908:     }) : fn;
2909:
2910:     return type === "unload" && "one" !== "one" ?
2911:         this.one( type, data, fn ) :
2912:         this.each(function() {
2913:             jQuery.event.add( this, type, handler, data );
2914:         });
2915: };
2916:
2917: jQuery.fn.extend({
2918:     unbind: function( type, fn ) {
2919:         ///    <summary>
2920:         ///        Unbinds a handler from one or more events for each matched element.
2921:         ///    </summary>
2922:         ///    <param name="type" type="String">One or more event types separated by a space. Built-in event type values are: blur, focus, load, resize, scroll, unload, click, dblclick, mousedown, mouseup, mousemove, mouseover, mouseout, mouseenter, mouseleave, change, select, submit, keydown, keypress, keyup, error .</param>
2923:         ///    <param name="fn" type="Function">A function to bind to the event on each of the set of matched elements. function callback(eventObject) such that this corresponds to the dom element.</param>
2924:
2925:         // Handle object literals
2926:         if ( typeof type === "object" && !type.preventDefault ) {
2927:             for ( var key in type ) {
2928:                 this.unbind(key, type[key]);
2929:             }
2930:             return this;
2931:         }
2932:
2933:         return this.each(function() {
2934:             jQuery.event.remove( this, type, fn );
2935:         });
2936:     },
2937:     trigger: function( type, data ) {
2938:         ///    <summary>
2939:         ///        Triggers a type of event on every matched element.
2940:         ///    </summary>
2941:         ///    <param name="type" type="String">One or more event types separated by a space. Built-in event type values are: blur, focus, load, resize, scroll, unload, click, dblclick, mousedown, mouseup, mousemove, mouseover, mouseout, mouseenter, mouseleave, change, select, submit, keydown, keypress, keyup, error .</param>
2942:         ///    <param name="data" optional="true" type="Array">Additional data passed to the event handler as additional arguments.</param>
2943:         ///    <param name="fn" type="Function">This parameter is undocumented.</param>
2944:
2945:         return this.each(function() {
2946:             jQuery.event.trigger( type, data, this );
2947:         });
2948:     },
2949:
2950:     triggerHandler: function( type, data ) {
2951:         ///    <summary>
2952:         ///        Triggers all bound event handlers on an element for a specific event type without executing the browser's default actions.
2953:         ///    </summary>
2954:         ///    <param name="type" type="String">One or more event types separated by a space. Built-in event type values are: blur, focus, load, resize, scroll, unload, click, dblclick, mousedown, mouseup, mousemove, mouseover, mouseout, mouseenter, mouseleave, change, select, submit, keydown, keypress, keyup, error .</param>
2955:         ///    <param name="data" optional="true" type="Array">Additional data passed to the event handler as additional arguments.</param>
2956:         ///    <param name="fn" type="Function">This parameter is undocumented.</param>
2957:
2958:         if ( this[0] ) {
2959:             var event = jQuery.Event( type );
2960:             event.preventDefault();
2961:             event.stopPropagation();
2962:             jQuery.event.trigger( event, data, this[0] );
2963:             return event.result;
2964:         }
2965:     },
2966:
2967:     toggle: function( fn ) {
2968:         ///    <summary>
2969:         ///        Toggles among two or more function calls every other click.
2970:         ///    </summary>
2971:         ///    <param name="fn" type="Function">The functions among which to toggle execution</param>
2972:
2973:         // Save reference to arguments for access in closure
2974:         var args = arguments, i = 1;
2975:
2976:         // link all the functions, so any of them can unbind this click handler
2977:         while ( i < args.length ) {
2978:             jQuery.proxy( fn, args[ i++ ] );
2979:         }
2980:
2981:         return this.click( jQuery.proxy( fn, function( event ) {
2982:             // Figure out which function to execute
2983:             var lastToggle = ( jQuery.data( this, "lastToggle" + fn.guid ) || 0 ) % i;
2984:             jQuery.data( this, "lastToggle" + fn.guid, lastToggle + 1 );
2985:
2986:             // Make sure that clicks stop
2987:             event.preventDefault();
2988:
2989:             // and execute the function
2990:             return args[ lastToggle ].apply( this, arguments ) || false;
2991:         }));
2992:     },
2993:
2994:     hover: function( fnOver, fnOut ) {
2995:         ///    <summary>
2996:         ///        Simulates hovering (moving the mouse on or off of an object).
2997:         ///    </summary>
2998:         ///    <param name="fnOver" type="Function">The function to fire when the mouse is moved over a matched element.</param>
2999:         ///    <param name="fnOut" type="Function">The function to fire when the mouse is moved off of a matched element.</param>
3000:
3001:         return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );
3002:     }
3003: });
3004:
3005: //    jQuery.each(["live", "die"], function( i, name ) {
3006: //        jQuery.fn[ name ] = function( types, data, fn ) {
3007: //            var type, i = 0;
3008: //
3009: //            if ( jQuery.isFunction( data ) ) {
3010: //                fn = data;
3011: //                data = undefined;
3012: //            }
3013: //
3014: //            types = (types || "").split( /\s+/ );
3015: //
3016: //            while ( (type = types[ i++ ]) != null ) {
3017: //                type = type === "focus" ? "focusin" : // focus --> focusin
3018: //                        type === "blur" ? "focusout" : // blur --> focusout
3019: //                        type === "hover" ? types.push("mouseleave") && "mouseenter" : // hover support
3020: //                        type;
3021: //                
3022: //                if ( name === "live" ) {
3023: //                    // bind live handler
3024: //                    jQuery( this.context ).bind( liveConvert( type, this.selector ), {
3025: //                        data: data, selector: this.selector, live: type
3026: //                    }, fn );
3027: //
3028: //                } else {
3029: //                    // unbind live handler
3030: //                    jQuery( this.context ).unbind( liveConvert( type, this.selector ), fn ? { guid: fn.guid + this.selector + type } : null );
3031: //                }
3032: //            }
3033: //            
3034: //            return this;
3035: //        }
3036: //    });
3037:
3038: jQuery.fn[ "live" ] = function( types, data, fn ) {
3039:     ///    <summary>
3040:     ///        Attach a handler to the event for all elements which match the current selector, now or
3041:     ///        in the future.
3042:     ///    </summary>
3043:     ///    <param name="types" type="String">
3044:     ///        A string containing a JavaScript event type, such as "click" or "keydown".
3045:     ///    </param>
3046:     ///    <param name="data" type="Object">
3047:     ///        A map of data that will be passed to the event handler.
3048:     ///    </param>
3049:     ///    <param name="fn" type="Function">
3050:     ///        A function to execute at the time the event is triggered.
3051:     ///    </param>
3052:     ///    <returns type="jQuery" />
3053:
3054:     var type, i = 0;
3055:
3056:     if ( jQuery.isFunction( data ) ) {
3057:         fn = data;
3058:         data = undefined;
3059:     }
3060:
3061:     types = (types || "").split( /\s+/ );
3062:
3063:     while ( (type = types[ i++ ]) != null ) {
3064:         type = type === "focus" ? "focusin" : // focus --> focusin
3065:                 type === "blur" ? "focusout" : // blur --> focusout
3066:                 type === "hover" ? types.push("mouseleave") && "mouseenter" : // hover support
3067:                 type;
3068:         
3069:         if ( "live" === "live" ) {
3070:             // bind live handler
3071:             jQuery( this.context ).bind( liveConvert( type, this.selector ), {
3072:                 data: data, selector: this.selector, live: type
3073:             }, fn );
3074:
3075:         } else {
3076:             // unbind live handler
3077:             jQuery( this.context ).unbind( liveConvert( type, this.selector ), fn ? { guid: fn.guid + this.selector + type } : null );
3078:         }
3079:     }
3080:     
3081:     return this;
3082: }
3083:
3084: jQuery.fn[ "die" ] = function( types, data, fn ) {
3085:     ///    <summary>
3086:     ///        Remove all event handlers previously attached using .live() from the elements.
3087:     ///    </summary>
3088:     ///    <param name="types" type="String">
3089:     ///        A string containing a JavaScript event type, such as click or keydown.
3090:     ///    </param>
3091:     ///    <param name="data" type="Object">
3092:     ///        The function that is to be no longer executed.
3093:     ///    </param>
3094:     ///    <returns type="jQuery" />
3095:
3096:     var type, i = 0;
3097:
3098:     if ( jQuery.isFunction( data ) ) {
3099:         fn = data;
3100:         data = undefined;
3101:     }
3102:
3103:     types = (types || "").split( /\s+/ );
3104:
3105:     while ( (type = types[ i++ ]) != null ) {
3106:         type = type === "focus" ? "focusin" : // focus --> focusin
3107:                 type === "blur" ? "focusout" : // blur --> focusout
3108:                 type === "hover" ? types.push("mouseleave") && "mouseenter" : // hover support
3109:                 type;
3110:         
3111:         if ( "die" === "live" ) {
3112:             // bind live handler
3113:             jQuery( this.context ).bind( liveConvert( type, this.selector ), {
3114:                 data: data, selector: this.selector, live: type
3115:             }, fn );
3116:
3117:         } else {
3118:             // unbind live handler
3119:             jQuery( this.context ).unbind( liveConvert( type, this.selector ), fn ? { guid: fn.guid + this.selector + type } : null );
3120:         }
3121:     }
3122:     
3123:     return this;
3124: }
3125:
3126: function liveHandler( event ) {
3127:     var stop, elems = [], selectors = [], args = arguments,
3128:         related, match, fn, elem, j, i, l, data,
3129:         live = jQuery.extend({}, jQuery.data( this, "events" ).live);
3130:
3131:     // Make sure we avoid non-left-click bubbling in Firefox (#3861)
3132:     if ( event.button && event.type === "click" ) {
3133:         return;
3134:     }
3135:
3136:     for ( j in live ) {
3137:         fn = live[j];
3138:         if ( fn.live === event.type ||
3139:                 fn.altLive && jQuery.inArray(event.type, fn.altLive) > -1 ) {
3140:
3141:             data = fn.data;
3142:             if ( !(data.beforeFilter && data.beforeFilter[event.type] &&
3143:                     !data.beforeFilter[event.type](event)) ) {
3144:                 selectors.push( fn.selector );
3145:             }
3146:         } else {
3147:             delete live[j];
3148:         }
3149:     }
3150:
3151:     match = jQuery( event.target ).closest( selectors, event.currentTarget );
3152:
3153:     for ( i = 0, l = match.length; i < l; i++ ) {
3154:         for ( j in live ) {
3155:             fn = live[j];
3156:             elem = match[i].elem;
3157:             related = null;
3158:
3159:             if ( match[i].selector === fn.selector ) {
3160:                 // Those two events require additional checking
3161:                 if ( fn.live === "mouseenter" || fn.live === "mouseleave" ) {
3162:                     related = jQuery( event.relatedTarget ).closest( fn.selector )[0];
3163:                 }
3164:
3165:                 if ( !related || related !== elem ) {
3166:                     elems.push({ elem: elem, fn: fn });
3167:                 }
3168:             }
3169:         }
3170:     }
3171:
3172:     for ( i = 0, l = elems.length; i < l; i++ ) {
3173:         match = elems[i];
3174:         event.currentTarget = match.elem;
3175:         event.data = match.fn.data;
3176:         if ( match.fn.apply( match.elem, args ) === false ) {
3177:             stop = false;
3178:             break;
3179:         }
3180:     }
3181:
3182:     return stop;
3183: }
3184:
3185: function liveConvert( type, selector ) {
3186:     return "live." + (type ? type + "." : "") + selector.replace(/\./g, "`").replace(/ /g, "&");
3187: }
3188:
3189: //    jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " +
3190: //        "mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " +
3191: //        "change select submit keydown keypress keyup error").split(" "), function( i, name ) {
3192: //
3193: //        // Handle event binding
3194: //        jQuery.fn[ name ] = function( fn ) {
3195: //            return fn ? this.bind( name, fn ) : this.trigger( name );
3196: //        };
3197: //
3198: //        if ( jQuery.attrFn ) {
3199: //            jQuery.attrFn[ name ] = true;
3200: //        }
3201: //    });
3202:
3203: jQuery.fn[ "blur" ] = function( fn ) {
3204:     ///    <summary>
3205:     ///        1: blur() - Triggers the blur event of each matched element.
3206:     ///        2: blur(fn) - Binds a function to the blur event of each matched element.
3207:     ///    </summary>
3208:     ///    <param name="fn" type="Function">The function to execute.</param>
3209:     ///    <returns type="jQuery" />
3210:
3211:     return fn ? this.bind( "blur", fn ) : this.trigger( "blur" );
3212: };
3213:
3214: jQuery.fn[ "focus" ] = function( fn ) {
3215:     ///    <summary>
3216:     ///        1: focus() - Triggers the focus event of each matched element.
3217:     ///        2: focus(fn) - Binds a function to the focus event of each matched element.
3218:     ///    </summary>
3219:     ///    <param name="fn" type="Function">The function to execute.</param>
3220:     ///    <returns type="jQuery" />
3221:
3222:     return fn ? this.bind( "focus", fn ) : this.trigger( "focus" );
3223: };
3224:
3225: jQuery.fn[ "focusin" ] = function( fn ) {
3226:         ///    <summary>
3227:         ///        Bind an event handler to the "focusin" JavaScript event.
3228:         ///    </summary>
3229:         ///    <param name="fn" type="Function">
3230:         ///        A function to execute each time the event is triggered.
3231:         ///    </param>
3232:         ///    <returns type="jQuery" />
3233:
3234:     return fn ? this.bind( "focusin", fn ) : this.trigger( "focusin" );
3235: };
3236:
3237: jQuery.fn[ "focusout" ] = function( fn ) {
3238:         ///    <summary>
3239:         ///        Bind an event handler to the "focusout" JavaScript event.
3240:         ///    </summary>
3241:         ///    <param name="fn" type="Function">
3242:         ///        A function to execute each time the event is triggered.
3243:         ///    </param>
3244:         ///    <returns type="jQuery" />
3245:
3246:     return fn ? this.bind( "focusout", fn ) : this.trigger( "focusout" );
3247: };
3248:
3249: jQuery.fn[ "load" ] = function( fn ) {
3250:     ///    <summary>
3251:     ///        1: load() - Triggers the load event of each matched element.
3252:     ///        2: load(fn) - Binds a function to the load event of each matched element.
3253:     ///    </summary>
3254:     ///    <param name="fn" type="Function">The function to execute.</param>
3255:     ///    <returns type="jQuery" />
3256:
3257:     return fn ? this.bind( "load", fn ) : this.trigger( "load" );
3258: };
3259:
3260: jQuery.fn[ "resize" ] = function( fn ) {
3261:     ///    <summary>
3262:     ///        1: resize() - Triggers the resize event of each matched element.
3263:     ///        2: resize(fn) - Binds a function to the resize event of each matched element.
3264:     ///    </summary>
3265:     ///    <param name="fn" type="Function">The function to execute.</param>
3266:     ///    <returns type="jQuery" />
3267:
3268:     return fn ? this.bind( "resize", fn ) : this.trigger( "resize" );
3269: };
3270:
3271: jQuery.fn[ "scroll" ] = function( fn ) {
3272:     ///    <summary>
3273:     ///        1: scroll() - Triggers the scroll event of each matched element.
3274:     ///        2: scroll(fn) - Binds a function to the scroll event of each matched element.
3275:     ///    </summary>
3276:     ///    <param name="fn" type="Function">The function to execute.</param>
3277:     ///    <returns type="jQuery" />
3278:
3279:     return fn ? this.bind( "scroll", fn ) : this.trigger( "scroll" );
3280: };
3281:
3282: jQuery.fn[ "unload" ] = function( fn ) {
3283:     ///    <summary>
3284:     ///        1: unload() - Triggers the unload event of each matched element.
3285:     ///        2: unload(fn) - Binds a function to the unload event of each matched element.
3286:     ///    </summary>
3287:     ///    <param name="fn" type="Function">The function to execute.</param>
3288:     ///    <returns type="jQuery" />
3289:
3290:     return fn ? this.bind( "unload", fn ) : this.trigger( "unload" );
3291: };
3292:
3293: jQuery.fn[ "click" ] = function( fn ) {
3294:     ///    <summary>
3295:     ///        1: click() - Triggers the click event of each matched element.
3296:     ///        2: click(fn) - Binds a function to the click event of each matched element.
3297:     ///    </summary>
3298:     ///    <param name="fn" type="Function">The function to execute.</param>
3299:     ///    <returns type="jQuery" />
3300:
3301:     return fn ? this.bind( "click", fn ) : this.trigger( "click" );
3302: };
3303:
3304: jQuery.fn[ "dblclick" ] = function( fn ) {
3305:     ///    <summary>
3306:     ///        1: dblclick() - Triggers the dblclick event of each matched element.
3307:     ///        2: dblclick(fn) - Binds a function to the dblclick event of each matched element.
3308:     ///    </summary>
3309:     ///    <param name="fn" type="Function">The function to execute.</param>
3310:     ///    <returns type="jQuery" />
3311:
3312:     return fn ? this.bind( "dblclick", fn ) : this.trigger( "dblclick" );
3313: };
3314:
3315: jQuery.fn[ "mousedown" ] = function( fn ) {
3316:     ///    <summary>
3317:     ///        Binds a function to the mousedown event of each matched element.
3318:     ///    </summary>
3319:     ///    <param name="fn" type="Function">The function to execute.</param>
3320:     ///    <returns type="jQuery" />
3321:
3322:     return fn ? this.bind( "mousedown", fn ) : this.trigger( "mousedown" );
3323: };
3324:
3325: jQuery.fn[ "mouseup" ] = function( fn ) {
3326:     ///    <summary>
3327:     ///        Bind a function to the mouseup event of each matched element.
3328:     ///    </summary>
3329:     ///    <param name="fn" type="Function">The function to execute.</param>
3330:     ///    <returns type="jQuery" />
3331:
3332:     return fn ? this.bind( "mouseup", fn ) : this.trigger( "mouseup" );
3333: };
3334:
3335: jQuery.fn[ "mousemove" ] = function( fn ) {
3336:     ///    <summary>
3337:     ///        Bind a function to the mousemove event of each matched element.
3338:     ///    </summary>
3339:     ///    <param name="fn" type="Function">The function to execute.</param>
3340:     ///    <returns type="jQuery" />
3341:
3342:     return fn ? this.bind( "mousemove", fn ) : this.trigger( "mousemove" );
3343: };
3344:
3345: jQuery.fn[ "mouseover" ] = function( fn ) {
3346:     ///    <summary>
3347:     ///        Bind a function to the mouseover event of each matched element.
3348:     ///    </summary>
3349:     ///    <param name="fn" type="Function">The function to execute.</param>
3350:     ///    <returns type="jQuery" />
3351:
3352:     return fn ? this.bind( "mouseover", fn ) : this.trigger( "mouseover" );
3353: };
3354:
3355: jQuery.fn[ "mouseout" ] = function( fn ) {
3356:     ///    <summary>
3357:     ///        Bind a function to the mouseout event of each matched element.
3358:     ///    </summary>
3359:     ///    <param name="fn" type="Function">The function to execute.</param>
3360:     ///    <returns type="jQuery" />
3361:
3362:     return fn ? this.bind( "mouseout", fn ) : this.trigger( "mouseout" );
3363: };
3364:
3365: jQuery.fn[ "mouseenter" ] = function( fn ) {
3366:     ///    <summary>
3367:     ///        Bind a function to the mouseenter event of each matched element.
3368:     ///    </summary>
3369:     ///    <param name="fn" type="Function">The function to execute.</param>
3370:     ///    <returns type="jQuery" />
3371:
3372:     return fn ? this.bind( "mouseenter", fn ) : this.trigger( "mouseenter" );
3373: };
3374:
3375: jQuery.fn[ "mouseleave" ] = function( fn ) {
3376:     ///    <summary>
3377:     ///        Bind a function to the mouseleave event of each matched element.
3378:     ///    </summary>
3379:     ///    <param name="fn" type="Function">The function to execute.</param>
3380:     ///    <returns type="jQuery" />
3381:
3382:     return fn ? this.bind( "mouseleave", fn ) : this.trigger( "mouseleave" );
3383: };
3384:
3385: jQuery.fn[ "change" ] = function( fn ) {
3386:     ///    <summary>
3387:     ///        1: change() - Triggers the change event of each matched element.
3388:     ///        2: change(fn) - Binds a function to the change event of each matched element.
3389:     ///    </summary>
3390:     ///    <param name="fn" type="Function">The function to execute.</param>
3391:     ///    <returns type="jQuery" />
3392:
3393:     return fn ? this.bind( "change", fn ) : this.trigger( "change" );
3394: };
3395:
3396: jQuery.fn[ "select" ] = function( fn ) {
3397:     ///    <summary>
3398:     ///        1: select() - Triggers the select event of each matched element.
3399:     ///        2: select(fn) - Binds a function to the select event of each matched element.
3400:     ///    </summary>
3401:     ///    <param name="fn" type="Function">The function to execute.</param>
3402:     ///    <returns type="jQuery" />
3403:
3404:     return fn ? this.bind( "select", fn ) : this.trigger( "select" );
3405: };
3406:
3407: jQuery.fn[ "submit" ] = function( fn ) {
3408:     ///    <summary>
3409:     ///        1: submit() - Triggers the submit event of each matched element.
3410:     ///        2: submit(fn) - Binds a function to the submit event of each matched element.
3411:     ///    </summary>
3412:     ///    <param name="fn" type="Function">The function to execute.</param>
3413:     ///    <returns type="jQuery" />
3414:
3415:     return fn ? this.bind( "submit", fn ) : this.trigger( "submit" );
3416: };
3417:
3418: jQuery.fn[ "keydown" ] = function( fn ) {
3419:     ///    <summary>
3420:     ///        1: keydown() - Triggers the keydown event of each matched element.
3421:     ///        2: keydown(fn) - Binds a function to the keydown event of each matched element.
3422:     ///    </summary>
3423:     ///    <param name="fn" type="Function">The function to execute.</param>
3424:     ///    <returns type="jQuery" />
3425:
3426:     return fn ? this.bind( "keydown", fn ) : this.trigger( "keydown" );
3427: };
3428:
3429: jQuery.fn[ "keypress" ] = function( fn ) {
3430:     ///    <summary>
3431:     ///        1: keypress() - Triggers the keypress event of each matched element.
3432:     ///        2: keypress(fn) - Binds a function to the keypress event of each matched element.
3433:     ///    </summary>
3434:     ///    <param name="fn" type="Function">The function to execute.</param>
3435:     ///    <returns type="jQuery" />
3436:
3437:     return fn ? this.bind( "keypress", fn ) : this.trigger( "keypress" );
3438: };
3439:
3440: jQuery.fn[ "keyup" ] = function( fn ) {
3441:     ///    <summary>
3442:     ///        1: keyup() - Triggers the keyup event of each matched element.
3443:     ///        2: keyup(fn) - Binds a function to the keyup event of each matched element.
3444:     ///    </summary>
3445:     ///    <param name="fn" type="Function">The function to execute.</param>
3446:     ///    <returns type="jQuery" />
3447:
3448:     return fn ? this.bind( "keyup", fn ) : this.trigger( "keyup" );
3449: };
3450:
3451: jQuery.fn[ "error" ] = function( fn ) {
3452:     ///    <summary>
3453:     ///        1: error() - Triggers the error event of each matched element.
3454:     ///        2: error(fn) - Binds a function to the error event of each matched element.
3455:     ///    </summary>
3456:     ///    <param name="fn" type="Function">The function to execute.</param>
3457:     ///    <returns type="jQuery" />
3458:
3459:     return fn ? this.bind( "error", fn ) : this.trigger( "error" );
3460: };
3461:
3462: // Prevent memory leaks in IE
3463: // Window isn't included so as not to unbind existing unload events
3464: // More info:
3465: // - http://isaacschlueter.com/2006/10/msie-memory-leaks/
3466: if ( window.attachEvent && !window.addEventListener ) {
3467:     window.attachEvent("onunload", function() {
3468:         for ( var id in jQuery.cache ) {
3469:             if ( jQuery.cache[ id ].handle ) {
3470:                 // Try/Catch is to handle iframes being unloaded, see #4280
3471:                 try {
3472:                     jQuery.event.remove( jQuery.cache[ id ].handle.elem );
3473:                 } catch(e) {}
3474:             }
3475:         }
3476:     });
3477: }
3478: /*!
3479: * Sizzle CSS Selector Engine - v1.0
3480: * Copyright 2009, The Dojo Foundation
3481: * Released under the MIT, BSD, and GPL Licenses.
3482: * More information: http://sizzlejs.com/
3483: */
3484: (function(){
3485:
3486: var chunker = /((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,
3487:     done = 0,
3488:     toString = Object.prototype.toString,
3489:     hasDuplicate = false,
3490:     baseHasDuplicate = true;
3491:
3492: // Here we check if the JavaScript engine is using some sort of
3493: // optimization where it does not always call our comparision
3494: // function. If that is the case, discard the hasDuplicate value.
3495: // Thus far that includes Google Chrome.
3496: [0, 0].sort(function(){
3497:     baseHasDuplicate = false;
3498:     return 0;
3499: });
3500:
3501: var Sizzle = function(selector, context, results, seed) {
3502:     results = results || [];
3503:     var origContext = context = context || document;
3504:
3505:     if ( context.nodeType !== 1 && context.nodeType !== 9 ) {
3506:         return [];
3507:     }
3508:     
3509:     if ( !selector || typeof selector !== "string" ) {
3510:         return results;
3511:     }
3512:
3513:     var parts = [], m, set, checkSet, extra, prune = true, contextXML = isXML(context),
3514:         soFar = selector;
3515:     
3516:     // Reset the position of the chunker regexp (start from head)
3517:     while ( (chunker.exec(""), m = chunker.exec(soFar)) !== null ) {
3518:         soFar = m[3];
3519:         
3520:         parts.push( m[1] );
3521:         
3522:         if ( m[2] ) {
3523:             extra = m[3];
3524:             break;
3525:         }
3526:     }
3527:
3528:     if ( parts.length > 1 && origPOS.exec( selector ) ) {
3529:         if ( parts.length === 2 && Expr.relative[ parts[0] ] ) {
3530:             set = posProcess( parts[0] + parts[1], context );
3531:         } else {
3532:             set = Expr.relative[ parts[0] ] ?
3533:                 [ context ] :
3534:                 Sizzle( parts.shift(), context );
3535:
3536:             while ( parts.length ) {
3537:                 selector = parts.shift();
3538:
3539:                 if ( Expr.relative[ selector ] ) {
3540:                     selector += parts.shift();
3541:                 }
3542:                 
3543:                 set = posProcess( selector, set );
3544:             }
3545:         }
3546:     } else {
3547:         // Take a shortcut and set the context if the root selector is an ID
3548:         // (but not if it'll be faster if the inner selector is an ID)
3549:         if ( !seed && parts.length > 1 && context.nodeType === 9 && !contextXML &&
3550:                 Expr.match.ID.test(parts[0]) && !Expr.match.ID.test(parts[parts.length - 1]) ) {
3551:             var ret = Sizzle.find( parts.shift(), context, contextXML );
3552:             context = ret.expr ? Sizzle.filter( ret.expr, ret.set )[0] : ret.set[0];
3553:         }
3554:
3555:         if ( context ) {
3556:             var ret = seed ?
3557:                 { expr: parts.pop(), set: makeArray(seed) } :
3558:                 Sizzle.find( parts.pop(), parts.length === 1 && (parts[0] === "~" || parts[0] === "+") && context.parentNode ? context.parentNode : context, contextXML );
3559:             set = ret.expr ? Sizzle.filter( ret.expr, ret.set ) : ret.set;
3560:
3561:             if ( parts.length > 0 ) {
3562:                 checkSet = makeArray(set);
3563:             } else {
3564:                 prune = false;
3565:             }
3566:
3567:             while ( parts.length ) {
3568:                 var cur = parts.pop(), pop = cur;
3569:
3570:                 if ( !Expr.relative[ cur ] ) {
3571:                     cur = "";
3572:                 } else {
3573:                     pop = parts.pop();
3574:                 }
3575:
3576:                 if ( pop == null ) {
3577:                     pop = context;
3578:                 }
3579:
3580:                 Expr.relative[ cur ]( checkSet, pop, contextXML );
3581:             }
3582:         } else {
3583:             checkSet = parts = [];
3584:         }
3585:     }
3586:
3587:     if ( !checkSet ) {
3588:         checkSet = set;
3589:     }
3590:
3591:     if ( !checkSet ) {
3592:         Sizzle.error( cur || selector );
3593:     }
3594:
3595:     if ( toString.call(checkSet) === "[object Array]" ) {
3596:         if ( !prune ) {
3597:             results.push.apply( results, checkSet );
3598:         } else if ( context && context.nodeType === 1 ) {
3599:             for ( var i = 0; checkSet[i] != null; i++ ) {
3600:                 if ( checkSet[i] && (checkSet[i] === true || checkSet[i].nodeType === 1 && contains(context, checkSet[i])) ) {
3601:                     results.push( set[i] );
3602:                 }
3603:             }
3604:         } else {
3605:             for ( var i = 0; checkSet[i] != null; i++ ) {
3606:                 if ( checkSet[i] && checkSet[i].nodeType === 1 ) {
3607:                     results.push( set[i] );
3608:                 }
3609:             }
3610:         }
3611:     } else {
3612:         makeArray( checkSet, results );
3613:     }
3614:
3615:     if ( extra ) {
3616:         Sizzle( extra, origContext, results, seed );
3617:         Sizzle.uniqueSort( results );
3618:     }
3619:
3620:     return results;
3621: };
3622:
3623: Sizzle.uniqueSort = function(results){
3624:     ///    <summary>
3625:     ///        Removes all duplicate elements from an array of elements.
3626:     ///    </summary>
3627:     ///    <param name="array" type="Array<Element>">The array to translate</param>
3628:     ///    <returns type="Array<Element>">The array after translation.</returns>
3629:
3630:     if ( sortOrder ) {
3631:         hasDuplicate = baseHasDuplicate;
3632:         results.sort(sortOrder);
3633:
3634:         if ( hasDuplicate ) {
3635:             for ( var i = 1; i < results.length; i++ ) {
3636:                 if ( results[i] === results[i-1] ) {
3637:                     results.splice(i--, 1);
3638:                 }
3639:             }
3640:         }
3641:     }
3642:
3643:     return results;
3644: };
3645:
3646: Sizzle.matches = function(expr, set){
3647:     return Sizzle(expr, null, null, set);
3648: };
3649:
3650: Sizzle.find = function(expr, context, isXML){
3651:     var set, match;
3652:
3653:     if ( !expr ) {
3654:         return [];
3655:     }
3656:
3657:     for ( var i = 0, l = Expr.order.length; i < l; i++ ) {
3658:         var type = Expr.order[i], match;
3659:         
3660:         if ( (match = Expr.leftMatch[ type ].exec( expr )) ) {
3661:             var left = match[1];
3662:             match.splice(1,1);
3663:
3664:             if ( left.substr( left.length - 1 ) !== "\\" ) {
3665:                 match[1] = (match[1] || "").replace(/\\/g, "");
3666:                 set = Expr.find[ type ]( match, context, isXML );
3667:                 if ( set != null ) {
3668:                     expr = expr.replace( Expr.match[ type ], "" );
3669:                     break;
3670:                 }
3671:             }
3672:         }
3673:     }
3674:
3675:     if ( !set ) {
3676:         set = context.getElementsByTagName("*");
3677:     }
3678:
3679:     return {set: set, expr: expr};
3680: };
3681:
3682: Sizzle.filter = function(expr, set, inplace, not){
3683:     var old = expr, result = [], curLoop = set, match, anyFound,
3684:         isXMLFilter = set && set[0] && isXML(set[0]);
3685:
3686:     while ( expr && set.length ) {
3687:         for ( var type in Expr.filter ) {
3688:             if ( (match = Expr.leftMatch[ type ].exec( expr )) != null && match[2] ) {
3689:                 var filter = Expr.filter[ type ], found, item, left = match[1];
3690:                 anyFound = false;
3691:
3692:                 match.splice(1,1);
3693:
3694:                 if ( left.substr( left.length - 1 ) === "\\" ) {
3695:                     continue;
3696:                 }
3697:
3698:                 if ( curLoop === result ) {
3699:                     result = [];
3700:                 }
3701:
3702:                 if ( Expr.preFilter[ type ] ) {
3703:                     match = Expr.preFilter[ type ]( match, curLoop, inplace, result, not, isXMLFilter );
3704:
3705:                     if ( !match ) {
3706:                         anyFound = found = true;
3707:                     } else if ( match === true ) {
3708:                         continue;
3709:                     }
3710:                 }
3711:
3712:                 if ( match ) {
3713:                     for ( var i = 0; (item = curLoop[i]) != null; i++ ) {
3714:                         if ( item ) {
3715:                             found = filter( item, match, i, curLoop );
3716:                             var pass = not ^ !!found;
3717:
3718:                             if ( inplace && found != null ) {
3719:                                 if ( pass ) {
3720:                                     anyFound = true;
3721:                                 } else {
3722:                                     curLoop[i] = false;
3723:                                 }
3724:                             } else if ( pass ) {
3725:                                 result.push( item );
3726:                                 anyFound = true;
3727:                             }
3728:                         }
3729:                     }
3730:                 }
3731:
3732:                 if ( found !== undefined ) {
3733:                     if ( !inplace ) {
3734:                         curLoop = result;
3735:                     }
3736:
3737:                     expr = expr.replace( Expr.match[ type ], "" );
3738:
3739:                     if ( !anyFound ) {
3740:                         return [];
3741:                     }
3742:
3743:                     break;
3744:                 }
3745:             }
3746:         }
3747:
3748:         // Improper expression
3749:         if ( expr === old ) {
3750:             if ( anyFound == null ) {
3751:                 Sizzle.error( expr );
3752:             } else {
3753:                 break;
3754:             }
3755:         }
3756:
3757:         old = expr;
3758:     }
3759:
3760:     return curLoop;
3761: };
3762:
3763: Sizzle.error = function( msg ) {
3764:     throw "Syntax error, unrecognized expression: " + msg;
3765: };
3766:
3767: var Expr = Sizzle.selectors = {
3768:     order: [ "ID", "NAME", "TAG" ],
3769:     match: {
3770:         ID: /#((?:[\w\u00c0-\uFFFF-]|\\.)+)/,
3771:         CLASS: /\.((?:[\w\u00c0-\uFFFF-]|\\.)+)/,
3772:         NAME: /\[name=['"]*((?:[\w\u00c0-\uFFFF-]|\\.)+)['"]*\]/,
3773:         ATTR: /\[\s*((?:[\w\u00c0-\uFFFF-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,
3774:         TAG: /^((?:[\w\u00c0-\uFFFF\*-]|\\.)+)/,
3775:         CHILD: /:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/,
3776:         POS: /:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/,
3777:         PSEUDO: /:((?:[\w\u00c0-\uFFFF-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/
3778:     },
3779:     leftMatch: {},
3780:     attrMap: {
3781:         "class": "className",
3782:         "for": "htmlFor"
3783:     },
3784:     attrHandle: {
3785:         href: function(elem){
3786:             return elem.getAttribute("href");
3787:         }
3788:     },
3789:     relative: {
3790:         "+": function(checkSet, part){
3791:             var isPartStr = typeof part === "string",
3792:                 isTag = isPartStr && !/\W/.test(part),
3793:                 isPartStrNotTag = isPartStr && !isTag;
3794:
3795:             if ( isTag ) {
3796:                 part = part.toLowerCase();
3797:             }
3798:
3799:             for ( var i = 0, l = checkSet.length, elem; i < l; i++ ) {
3800:                 if ( (elem = checkSet[i]) ) {
3801:                     while ( (elem = elem.previousSibling) && elem.nodeType !== 1 ) {}
3802:
3803:                     checkSet[i] = isPartStrNotTag || elem && elem.nodeName.toLowerCase() === part ?
3804:                         elem || false :
3805:                         elem === part;
3806:                 }
3807:             }
3808:
3809:             if ( isPartStrNotTag ) {
3810:                 Sizzle.filter( part, checkSet, true );
3811:             }
3812:         },
3813:         ">": function(checkSet, part){
3814:             var isPartStr = typeof part === "string";
3815:
3816:             if ( isPartStr && !/\W/.test(part) ) {
3817:                 part = part.toLowerCase();
3818:
3819:                 for ( var i = 0, l = checkSet.length; i < l; i++ ) {
3820:                     var elem = checkSet[i];
3821:                     if ( elem ) {
3822:                         var parent = elem.parentNode;
3823:                         checkSet[i] = parent.nodeName.toLowerCase() === part ? parent : false;
3824:                     }
3825:                 }
3826:             } else {
3827:                 for ( var i = 0, l = checkSet.length; i < l; i++ ) {
3828:                     var elem = checkSet[i];
3829:                     if ( elem ) {
3830:                         checkSet[i] = isPartStr ?
3831:                             elem.parentNode :
3832:                             elem.parentNode === part;
3833:                     }
3834:                 }
3835:
3836:                 if ( isPartStr ) {
3837:                     Sizzle.filter( part, checkSet, true );
3838:                 }
3839:             }
3840:         },
3841:         "": function(checkSet, part, isXML){
3842:             var doneName = done++, checkFn = dirCheck;
3843:
3844:             if ( typeof part === "string" && !/\W/.test(part) ) {
3845:                 var nodeCheck = part = part.toLowerCase();
3846:                 checkFn = dirNodeCheck;
3847:             }
3848:
3849:             checkFn("parentNode", part, doneName, checkSet, nodeCheck, isXML);
3850:         },
3851:         "~": function(checkSet, part, isXML){
3852:             var doneName = done++, checkFn = dirCheck;
3853:
3854:             if ( typeof part === "string" && !/\W/.test(part) ) {
3855:                 var nodeCheck = part = part.toLowerCase();
3856:                 checkFn = dirNodeCheck;
3857:             }
3858:
3859:             checkFn("previousSibling", part, doneName, checkSet, nodeCheck, isXML);
3860:         }
3861:     },
3862:     find: {
3863:         ID: function(match, context, isXML){
3864:             if ( typeof context.getElementById !== "undefined" && !isXML ) {
3865:                 var m = context.getElementById(match[1]);
3866:                 return m ? [m] : [];
3867:             }
3868:         },
3869:         NAME: function(match, context){
3870:             if ( typeof context.getElementsByName !== "undefined" ) {
3871:                 var ret = [], results = context.getElementsByName(match[1]);
3872:
3873:                 for ( var i = 0, l = results.length; i < l; i++ ) {
3874:                     if ( results[i].getAttribute("name") === match[1] ) {
3875:                         ret.push( results[i] );
3876:                     }
3877:                 }
3878:
3879:                 return ret.length === 0 ? null : ret;
3880:             }
3881:         },
3882:         TAG: function(match, context){
3883:             return context.getElementsByTagName(match[1]);
3884:         }
3885:     },
3886:     preFilter: {
3887:         CLASS: function(match, curLoop, inplace, result, not, isXML){
3888:             match = " " + match[1].replace(/\\/g, "") + " ";
3889:
3890:             if ( isXML ) {
3891:                 return match;
3892:             }
3893:
3894:             for ( var i = 0, elem; (elem = curLoop[i]) != null; i++ ) {
3895:                 if ( elem ) {
3896:                     if ( not ^ (elem.className && (" " + elem.className + " ").replace(/[\t\n]/g, " ").indexOf(match) >= 0) ) {
3897:                         if ( !inplace ) {
3898:                             result.push( elem );
3899:                         }
3900:                     } else if ( inplace ) {
3901:                         curLoop[i] = false;
3902:                     }
3903:                 }
3904:             }
3905:
3906:             return false;
3907:         },
3908:         ID: function(match){
3909:             return match[1].replace(/\\/g, "");
3910:         },
3911:         TAG: function(match, curLoop){
3912:             return match[1].toLowerCase();
3913:         },
3914:         CHILD: function(match){
3915:             if ( match[1] === "nth" ) {
3916:                 // parse equations like 'even', 'odd', '5', '2n', '3n+2', '4n-1', '-n+6'
3917:                 var test = /(-?)(\d*)n((?:\+|-)?\d*)/.exec(
3918:                     match[2] === "even" && "2n" || match[2] === "odd" && "2n+1" ||
3919:                     !/\D/.test( match[2] ) && "0n+" + match[2] || match[2]);
3920:
3921:                 // calculate the numbers (first)n+(last) including if they are negative
3922:                 match[2] = (test[1] + (test[2] || 1)) - 0;
3923:                 match[3] = test[3] - 0;
3924:             }
3925:
3926:             // TODO: Move to normal caching system
3927:             match[0] = done++;
3928:
3929:             return match;
3930:         },
3931:         ATTR: function(match, curLoop, inplace, result, not, isXML){
3932:             var name = match[1].replace(/\\/g, "");
3933:             
3934:             if ( !isXML && Expr.attrMap[name] ) {
3935:                 match[1] = Expr.attrMap[name];
3936:             }
3937:
3938:             if ( match[2] === "~=" ) {
3939:                 match[4] = " " + match[4] + " ";
3940:             }
3941:
3942:             return match;
3943:         },
3944:         PSEUDO: function(match, curLoop, inplace, result, not){
3945:             if ( match[1] === "not" ) {
3946:                 // If we're dealing with a complex expression, or a simple one
3947:                 if ( ( chunker.exec(match[3]) || "" ).length > 1 || /^\w/.test(match[3]) ) {
3948:                     match[3] = Sizzle(match[3], null, null, curLoop);
3949:                 } else {
3950:                     var ret = Sizzle.filter(match[3], curLoop, inplace, true ^ not);
3951:                     if ( !inplace ) {
3952:                         result.push.apply( result, ret );
3953:                     }
3954:                     return false;
3955:                 }
3956:             } else if ( Expr.match.POS.test( match[0] ) || Expr.match.CHILD.test( match[0] ) ) {
3957:                 return true;
3958:             }
3959:             
3960:             return match;
3961:         },
3962:         POS: function(match){
3963:             match.unshift( true );
3964:             return match;
3965:         }
3966:     },
3967:     filters: {
3968:         enabled: function(elem){
3969:             return elem.disabled === false && elem.type !== "hidden";
3970:         },
3971:         disabled: function(elem){
3972:             return elem.disabled === true;
3973:         },
3974:         checked: function(elem){
3975:             return elem.checked === true;
3976:         },
3977:         selected: function(elem){
3978:             // Accessing this property makes selected-by-default
3979:             // options in Safari work properly
3980:             elem.parentNode.selectedIndex;
3981:             return elem.selected === true;
3982:         },
3983:         parent: function(elem){
3984:             return !!elem.firstChild;
3985:         },
3986:         empty: function(elem){
3987:             return !elem.firstChild;
3988:         },
3989:         has: function(elem, i, match){
3990:             ///    <summary>
3991:             ///        Internal use only; use hasClass('class')
3992:             ///    </summary>
3993:             ///    <private />
3994:
3995:             return !!Sizzle( match[3], elem ).length;
3996:         },
3997:         header: function(elem){
3998:             return /h\d/i.test( elem.nodeName );
3999:         },
4000:         text: function(elem){
4001:             return "text" === elem.type;
4002:         },
4003:         radio: function(elem){
4004:             return "radio" === elem.type;
4005:         },
4006:         checkbox: function(elem){
4007:             return "checkbox" === elem.type;
4008:         },
4009:         file: function(elem){
4010:             return "file" === elem.type;
4011:         },
4012:         password: function(elem){
4013:             return "password" === elem.type;
4014:         },
4015:         submit: function(elem){
4016:             return "submit" === elem.type;
4017:         },
4018:         image: function(elem){
4019:             return "image" === elem.type;
4020:         },
4021:         reset: function(elem){
4022:             return "reset" === elem.type;
4023:         },
4024:         button: function(elem){
4025:             return "button" === elem.type || elem.nodeName.toLowerCase() === "button";
4026:         },
4027:         input: function(elem){
4028:             return /input|select|textarea|button/i.test(elem.nodeName);
4029:         }
4030:     },
4031:     setFilters: {
4032:         first: function(elem, i){
4033:             return i === 0;
4034:         },
4035:         last: function(elem, i, match, array){
4036:             return i === array.length - 1;
4037:         },
4038:         even: function(elem, i){
4039:             return i % 2 === 0;
4040:         },
4041:         odd: function(elem, i){
4042:             return i % 2 === 1;
4043:         },
4044:         lt: function(elem, i, match){
4045:             return i < match[3] - 0;
4046:         },
4047:         gt: function(elem, i, match){
4048:             return i > match[3] - 0;
4049:         },
4050:         nth: function(elem, i, match){
4051:             return match[3] - 0 === i;
4052:         },
4053:         eq: function(elem, i, match){
4054:             return match[3] - 0 === i;
4055:         }
4056:     },
4057:     filter: {
4058:         PSEUDO: function(elem, match, i, array){
4059:             var name = match[1], filter = Expr.filters[ name ];
4060:
4061:             if ( filter ) {
4062:                 return filter( elem, i, match, array );
4063:             } else if ( name === "contains" ) {
4064:                 return (elem.textContent || elem.innerText || getText([ elem ]) || "").indexOf(match[3]) >= 0;
4065:             } else if ( name === "not" ) {
4066:                 var not = match[3];
4067:
4068:                 for ( var i = 0, l = not.length; i < l; i++ ) {
4069:                     if ( not[i] === elem ) {
4070:                         return false;
4071:                     }
4072:                 }
4073:
4074:                 return true;
4075:             } else {
4076:                 Sizzle.error( "Syntax error, unrecognized expression: " + name );
4077:             }
4078:         },
4079:         CHILD: function(elem, match){
4080:             var type = match[1], node = elem;
4081:             switch (type) {
4082:                 case 'only':
4083:                 case 'first':
4084:                     while ( (node = node.previousSibling) )     {
4085:                         if ( node.nodeType === 1 ) {
4086:                             return false;
4087:                         }
4088:                     }
4089:                     if ( type === "first" ) {
4090:                         return true;
4091:                     }
4092:                     node = elem;
4093:                 case 'last':
4094:                     while ( (node = node.nextSibling) )     {
4095:                         if ( node.nodeType === 1 ) {
4096:                             return false;
4097:                         }
4098:                     }
4099:                     return true;
4100:                 case 'nth':
4101:                     var first = match[2], last = match[3];
4102:
4103:                     if ( first === 1 && last === 0 ) {
4104:                         return true;
4105:                     }
4106:                     
4107:                     var doneName = match[0],
4108:                         parent = elem.parentNode;
4109:     
4110:                     if ( parent && (parent.sizcache !== doneName || !elem.nodeIndex) ) {
4111:                         var count = 0;
4112:                         for ( node = parent.firstChild; node; node = node.nextSibling ) {
4113:                             if ( node.nodeType === 1 ) {
4114:                                 node.nodeIndex = ++count;
4115:                             }
4116:                         }
4117:                         parent.sizcache = doneName;
4118:                     }
4119:                     
4120:                     var diff = elem.nodeIndex - last;
4121:                     if ( first === 0 ) {
4122:                         return diff === 0;
4123:                     } else {
4124:                         return ( diff % first === 0 && diff / first >= 0 );
4125:                     }
4126:             }
4127:         },
4128:         ID: function(elem, match){
4129:             return elem.nodeType === 1 && elem.getAttribute("id") === match;
4130:         },
4131:         TAG: function(elem, match){
4132:             return (match === "*" && elem.nodeType === 1) || elem.nodeName.toLowerCase() === match;
4133:         },
4134:         CLASS: function(elem, match){
4135:             return (" " + (elem.className || elem.getAttribute("class")) + " ")
4136:                 .indexOf( match ) > -1;
4137:         },
4138:         ATTR: function(elem, match){
4139:             var name = match[1],
4140:                 result = Expr.attrHandle[ name ] ?
4141:                     Expr.attrHandle[ name ]( elem ) :
4142:                     elem[ name ] != null ?
4143:                         elem[ name ] :
4144:                         elem.getAttribute( name ),
4145:                 value = result + "",
4146:                 type = match[2],
4147:                 check = match[4];
4148:
4149:             return result == null ?
4150:                 type === "!=" :
4151:                 type === "=" ?
4152:                 value === check :
4153:                 type === "*=" ?
4154:                 value.indexOf(check) >= 0 :
4155:                 type === "~=" ?
4156:                 (" " + value + " ").indexOf(check) >= 0 :
4157:                 !check ?
4158:                 value && result !== false :
4159:                 type === "!=" ?
4160:                 value !== check :
4161:                 type === "^=" ?
4162:                 value.indexOf(check) === 0 :
4163:                 type === "$=" ?
4164:                 value.substr(value.length - check.length) === check :
4165:                 type === "|=" ?
4166:                 value === check || value.substr(0, check.length + 1) === check + "-" :
4167:                 false;
4168:         },
4169:         POS: function(elem, match, i, array){
4170:             var name = match[2], filter = Expr.setFilters[ name ];
4171:
4172:             if ( filter ) {
4173:                 return filter( elem, i, match, array );
4174:             }
4175:         }
4176:     }
4177: };
4178:
4179: var origPOS = Expr.match.POS;
4180:
4181: for ( var type in Expr.match ) {
4182:     Expr.match[ type ] = new RegExp( Expr.match[ type ].source + /(?![^\[]*\])(?![^\(]*\))/.source );
4183:     Expr.leftMatch[ type ] = new RegExp( /(^(?:.|\r|\n)*?)/.source + Expr.match[ type ].source.replace(/\\(\d+)/g, function(all, num){
4184:         return "\\" + (num - 0 + 1);
4185:     }));
4186: }
4187:
4188: var makeArray = function(array, results) {
4189:     array = Array.prototype.slice.call( array, 0 );
4190:
4191:     if ( results ) {
4192:         results.push.apply( results, array );
4193:         return results;
4194:     }
4195:     
4196:     return array;
4197: };
4198:
4199: // Perform a simple check to determine if the browser is capable of
4200: // converting a NodeList to an array using builtin methods.
4201: try {
4202:     Array.prototype.slice.call( document.documentElement.childNodes, 0 );
4203:
4204: // Provide a fallback method if it does not work
4205: } catch(e){
4206:     makeArray = function(array, results) {
4207:         var ret = results || [];
4208:
4209:         if ( toString.call(array) === "[object Array]" ) {
4210:             Array.prototype.push.apply( ret, array );
4211:         } else {
4212:             if ( typeof array.length === "number" ) {
4213:                 for ( var i = 0, l = array.length; i < l; i++ ) {
4214:                     ret.push( array[i] );
4215:                 }
4216:             } else {
4217:                 for ( var i = 0; array[i]; i++ ) {
4218:                     ret.push( array[i] );
4219:                 }
4220:             }
4221:         }
4222:
4223:         return ret;
4224:     };
4225: }
4226:
4227: var sortOrder;
4228:
4229: if ( document.documentElement.compareDocumentPosition ) {
4230:     sortOrder = function( a, b ) {
4231:         if ( !a.compareDocumentPosition || !b.compareDocumentPosition ) {
4232:             if ( a == b ) {
4233:                 hasDuplicate = true;
4234:             }
4235:             return a.compareDocumentPosition ? -1 : 1;
4236:         }
4237:
4238:         var ret = a.compareDocumentPosition(b) & 4 ? -1 : a === b ? 0 : 1;
4239:         if ( ret === 0 ) {
4240:             hasDuplicate = true;
4241:         }
4242:         return ret;
4243:     };
4244: } else if ( "sourceIndex" in document.documentElement ) {
4245:     sortOrder = function( a, b ) {
4246:         if ( !a.sourceIndex || !b.sourceIndex ) {
4247:             if ( a == b ) {
4248:                 hasDuplicate = true;
4249:             }
4250:             return a.sourceIndex ? -1 : 1;
4251:         }
4252:
4253:         var ret = a.sourceIndex - b.sourceIndex;
4254:         if ( ret === 0 ) {
4255:             hasDuplicate = true;
4256:         }
4257:         return ret;
4258:     };
4259: } else if ( document.createRange ) {
4260:     sortOrder = function( a, b ) {
4261:         if ( !a.ownerDocument || !b.ownerDocument ) {
4262:             if ( a == b ) {
4263:                 hasDuplicate = true;
4264:             }
4265:             return a.ownerDocument ? -1 : 1;
4266:         }
4267:
4268:         var aRange = a.ownerDocument.createRange(), bRange = b.ownerDocument.createRange();
4269:         aRange.setStart(a, 0);
4270:         aRange.setEnd(a, 0);
4271:         bRange.setStart(b, 0);
4272:         bRange.setEnd(b, 0);
4273:         var ret = aRange.compareBoundaryPoints(Range.START_TO_END, bRange);
4274:         if ( ret === 0 ) {
4275:             hasDuplicate = true;
4276:         }
4277:         return ret;
4278:     };
4279: }
4280:
4281: // Utility function for retreiving the text value of an array of DOM nodes
4282: function getText( elems ) {
4283:     var ret = "", elem;
4284:
4285:     for ( var i = 0; elems[i]; i++ ) {
4286:         elem = elems[i];
4287:
4288:         // Get the text from text nodes and CDATA nodes
4289:         if ( elem.nodeType === 3 || elem.nodeType === 4 ) {
4290:             ret += elem.nodeValue;
4291:
4292:         // Traverse everything else, except comment nodes
4293:         } else if ( elem.nodeType !== 8 ) {
4294:             ret += getText( elem.childNodes );
4295:         }
4296:     }
4297:
4298:     return ret;
4299: }
4300:
4301: // [vsdoc] The following function has been modified for IntelliSense.
4302: // Check to see if the browser returns elements by name when
4303: // querying by getElementById (and provide a workaround)
4304: (function(){
4305:     // We're going to inject a fake input element with a specified name
4306:     //    var form = document.createElement("div"),
4307:     //        id = "script" + (new Date).getTime();
4308:     //    form.innerHTML = "<a name='" + id + "'/>";
4309:
4310:     //    // Inject it into the root element, check its status, and remove it quickly
4311:     //    var root = document.documentElement;
4312:     //    root.insertBefore( form, root.firstChild );
4313:
4314:     // The workaround has to do additional checks after a getElementById
4315:     // Which slows things down for other browsers (hence the branching)
4316:     //    if ( document.getElementById( id ) ) {
4317:         Expr.find.ID = function(match, context, isXML){
4318:             if ( typeof context.getElementById !== "undefined" && !isXML ) {
4319:                 var m = context.getElementById(match[1]);
4320:                 return m ? m.id === match[1] || typeof m.getAttributeNode !== "undefined" && m.getAttributeNode("id").nodeValue === match[1] ? [m] : undefined : [];
4321:             }
4322:         };
4323:
4324:         Expr.filter.ID = function(elem, match){
4325:             var node = typeof elem.getAttributeNode !== "undefined" && elem.getAttributeNode("id");
4326:             return elem.nodeType === 1 && node && node.nodeValue === match;
4327:         };
4328:     //    }
4329:
4330:     //    root.removeChild( form );
4331:     root = form = null; // release memory in IE
4332: })();
4333:
4334: // [vsdoc] The following function has been modified for IntelliSense.
4335: (function(){
4336:     // Check to see if the browser returns only elements
4337:     // when doing getElementsByTagName("*")
4338:
4339:     // Create a fake element
4340:     //    var div = document.createElement("div");
4341:     //    div.appendChild( document.createComment("") );
4342:
4343:     // Make sure no comments are found
4344:     //    if ( div.getElementsByTagName("*").length > 0 ) {
4345:         Expr.find.TAG = function(match, context){
4346:             var results = context.getElementsByTagName(match[1]);
4347:
4348:             // Filter out possible comments
4349:             if ( match[1] === "*" ) {
4350:                 var tmp = [];
4351:
4352:                 for ( var i = 0; results[i]; i++ ) {
4353:                     if ( results[i].nodeType === 1 ) {
4354:                         tmp.push( results[i] );
4355:                     }
4356:                 }
4357:
4358:                 results = tmp;
4359:             }
4360:
4361:             return results;
4362:         };
4363:     //    }
4364:
4365:     // Check to see if an attribute returns normalized href attributes
4366:     //    div.innerHTML = "<a href='#'></a>";
4367:     //    if ( div.firstChild && typeof div.firstChild.getAttribute !== "undefined" &&
4368:     //            div.firstChild.getAttribute("href") !== "#" ) {
4369:         Expr.attrHandle.href = function(elem){
4370:             return elem.getAttribute("href", 2);
4371:         };
4372:     //    }
4373:
4374:     div = null; // release memory in IE
4375: })();
4376:
4377: if ( document.querySelectorAll ) {
4378:     (function(){
4379:         var oldSizzle = Sizzle, div = document.createElement("div");
4380:         div.innerHTML = "<p class='TEST'></p>";
4381:
4382:         // Safari can't handle uppercase or unicode characters when
4383:         // in quirks mode.
4384:         if ( div.querySelectorAll && div.querySelectorAll(".TEST").length === 0 ) {
4385:             return;
4386:         }
4387:     
4388:         Sizzle = function(query, context, extra, seed){
4389:             context = context || document;
4390:
4391:             // Only use querySelectorAll on non-XML documents
4392:             // (ID selectors don't work in non-HTML documents)
4393:             if ( !seed && context.nodeType === 9 && !isXML(context) ) {
4394:                 try {
4395:                     return makeArray( context.querySelectorAll(query), extra );
4396:                 } catch(e){}
4397:             }
4398:         
4399:             return oldSizzle(query, context, extra, seed);
4400:         };
4401:
4402:         for ( var prop in oldSizzle ) {
4403:             Sizzle[ prop ] = oldSizzle[ prop ];
4404:         }
4405:
4406:         div = null; // release memory in IE
4407:     })();
4408: }
4409:
4410: (function(){
4411:     var div = document.createElement("div");
4412:
4413:     div.innerHTML = "<div class='test e'></div><div class='test'></div>";
4414:
4415:     // Opera can't find a second classname (in 9.6)
4416:     // Also, make sure that getElementsByClassName actually exists
4417:     if ( !div.getElementsByClassName || div.getElementsByClassName("e").length === 0 ) {
4418:         return;
4419:     }
4420:
4421:     // Safari caches class attributes, doesn't catch changes (in 3.2)
4422:     div.lastChild.className = "e";
4423:
4424:     if ( div.getElementsByClassName("e").length === 1 ) {
4425:         return;
4426:     }
4427:     
4428:     Expr.order.splice(1, 0, "CLASS");
4429:     Expr.find.CLASS = function(match, context, isXML) {
4430:         if ( typeof context.getElementsByClassName !== "undefined" && !isXML ) {
4431:             return context.getElementsByClassName(match[1]);
4432:         }
4433:     };
4434:
4435:     div = null; // release memory in IE
4436: })();
4437:
4438: function dirNodeCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) {
4439:     for ( var i = 0, l = checkSet.length; i < l; i++ ) {
4440:         var elem = checkSet[i];
4441:         if ( elem ) {
4442:             elem = elem[dir];
4443:             var match = false;
4444:
4445:             while ( elem ) {
4446:                 if ( elem.sizcache === doneName ) {
4447:                     match = checkSet[elem.sizset];
4448:                     break;
4449:                 }
4450:
4451:                 if ( elem.nodeType === 1 && !isXML ){
4452:                     elem.sizcache = doneName;
4453:                     elem.sizset = i;
4454:                 }
4455:
4456:                 if ( elem.nodeName.toLowerCase() === cur ) {
4457:                     match = elem;
4458:                     break;
4459:                 }
4460:
4461:                 elem = elem[dir];
4462:             }
4463:
4464:             checkSet[i] = match;
4465:         }
4466:     }
4467: }
4468:
4469: function dirCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) {
4470:     for ( var i = 0, l = checkSet.length; i < l; i++ ) {
4471:         var elem = checkSet[i];
4472:         if ( elem ) {
4473:             elem = elem[dir];
4474:             var match = false;
4475:
4476:             while ( elem ) {
4477:                 if ( elem.sizcache === doneName ) {
4478:                     match = checkSet[elem.sizset];
4479:                     break;
4480:                 }
4481:
4482:                 if ( elem.nodeType === 1 ) {
4483:                     if ( !isXML ) {
4484:                         elem.sizcache = doneName;
4485:                         elem.sizset = i;
4486:                     }
4487:                     if ( typeof cur !== "string" ) {
4488:                         if ( elem === cur ) {
4489:                             match = true;
4490:                             break;
4491:                         }
4492:
4493:                     } else if ( Sizzle.filter( cur, [elem] ).length > 0 ) {
4494:                         match = elem;
4495:                         break;
4496:                     }
4497:                 }
4498:
4499:                 elem = elem[dir];
4500:             }
4501:
4502:             checkSet[i] = match;
4503:         }
4504:     }
4505: }
4506:
4507: var contains = document.compareDocumentPosition ? function(a, b){
4508:     ///    <summary>
4509:     ///        Check to see if a DOM node is within another DOM node.
4510:     ///    </summary>
4511:     ///    <param name="a" type="Object">
4512:     ///        The DOM element that may contain the other element.
4513:     ///    </param>
4514:     ///    <param name="b" type="Object">
4515:     ///        The DOM node that may be contained by the other element.
4516:     ///    </param>
4517:     ///    <returns type="Boolean" />
4518:
4519:     return a.compareDocumentPosition(b) & 16;
4520: } : function(a, b){
4521:     ///    <summary>
4522:     ///        Check to see if a DOM node is within another DOM node.
4523:     ///    </summary>
4524:     ///    <param name="a" type="Object">
4525:     ///        The DOM element that may contain the other element.
4526:     ///    </param>
4527:     ///    <param name="b" type="Object">
4528:     ///        The DOM node that may be contained by the other element.
4529:     ///    </param>
4530:     ///    <returns type="Boolean" />
4531:
4532:     return a !== b && (a.contains ? a.contains(b) : true);
4533: };
4534:
4535: var isXML = function(elem){
4536:     ///    <summary>
4537:     ///        Determines if the parameter passed is an XML document.
4538:     ///    </summary>
4539:     ///    <param name="elem" type="Object">The object to test</param>
4540:     ///    <returns type="Boolean">True if the parameter is an XML document; otherwise false.</returns>
4541:
4542:     // documentElement is verified for cases where it doesn't yet exist
4543:     // (such as loading iframes in IE - #4833)
4544:     var documentElement = (elem ? elem.ownerDocument || elem : 0).documentElement;
4545:     return documentElement ? documentElement.nodeName !== "HTML" : false;
4546: };
4547:
4548: var posProcess = function(selector, context){
4549:     var tmpSet = [], later = "", match,
4550:         root = context.nodeType ? [context] : context;
4551:
4552:     // Position selectors must be done after the filter
4553:     // And so must :not(positional) so we move all PSEUDOs to the end
4554:     while ( (match = Expr.match.PSEUDO.exec( selector )) ) {
4555:         later += match[0];
4556:         selector = selector.replace( Expr.match.PSEUDO, "" );
4557:     }
4558:
4559:     selector = Expr.relative[selector] ? selector + "*" : selector;
4560:
4561:     for ( var i = 0, l = root.length; i < l; i++ ) {
4562:         Sizzle( selector, root[i], tmpSet );
4563:     }
4564:
4565:     return Sizzle.filter( later, tmpSet );
4566: };
4567:
4568: // EXPOSE
4569: jQuery.find = Sizzle;
4570: jQuery.expr = Sizzle.selectors;
4571: jQuery.expr[":"] = jQuery.expr.filters;
4572: jQuery.unique = Sizzle.uniqueSort;
4573: jQuery.getText = getText;
4574: jQuery.isXMLDoc = isXML;
4575: jQuery.contains = contains;
4576:
4577: return;
4578:
4579: window.Sizzle = Sizzle;
4580:
4581: })();
4582: var runtil = /Until$/,
4583:     rparentsprev = /^(?:parents|prevUntil|prevAll)/,
4584:     // Note: This RegExp should be improved, or likely pulled from Sizzle
4585:     rmultiselector = /,/,
4586:     slice = Array.prototype.slice;
4587:
4588: // Implement the identical functionality for filter and not
4589: var winnow = function( elements, qualifier, keep ) {
4590:     if ( jQuery.isFunction( qualifier ) ) {
4591:         return jQuery.grep(elements, function( elem, i ) {
4592:             return !!qualifier.call( elem, i, elem ) === keep;
4593:         });
4594:
4595:     } else if ( qualifier.nodeType ) {
4596:         return jQuery.grep(elements, function( elem, i ) {
4597:             return (elem === qualifier) === keep;
4598:         });
4599:
4600:     } else if ( typeof qualifier === "string" ) {
4601:         var filtered = jQuery.grep(elements, function( elem ) {
4602:             return elem.nodeType === 1;
4603:         });
4604:
4605:         if ( isSimple.test( qualifier ) ) {
4606:             return jQuery.filter(qualifier, filtered, !keep);
4607:         } else {
4608:             qualifier = jQuery.filter( qualifier, filtered );
4609:         }
4610:     }
4611:
4612:     return jQuery.grep(elements, function( elem, i ) {
4613:         return (jQuery.inArray( elem, qualifier ) >= 0) === keep;
4614:     });
4615: };
4616:
4617: jQuery.fn.extend({
4618:     find: function( selector ) {
4619:         ///    <summary>
4620:         ///        Searches for all elements that match the specified expression.
4621:         ///        This method is a good way to find additional descendant
4622:         ///        elements with which to process.
4623:         ///        All searching is done using a jQuery expression. The expression can be
4624:         ///        written using CSS 1-3 Selector syntax, or basic XPath.
4625:         ///        Part of DOM/Traversing
4626:         ///    </summary>
4627:         ///    <returns type="jQuery" />
4628:         ///    <param name="selector" type="String">
4629:         ///        An expression to search with.
4630:         ///    </param>
4631:         ///    <returns type="jQuery" />
4632:
4633:         var ret = this.pushStack( "", "find", selector ), length = 0;
4634:
4635:         for ( var i = 0, l = this.length; i < l; i++ ) {
4636:             length = ret.length;
4637:             jQuery.find( selector, this[i], ret );
4638:
4639:             if ( i > 0 ) {
4640:                 // Make sure that the results are unique
4641:                 for ( var n = length; n < ret.length; n++ ) {
4642:                     for ( var r = 0; r < length; r++ ) {
4643:                         if ( ret[r] === ret[n] ) {
4644:                             ret.splice(n--, 1);
4645:                             break;
4646:                         }
4647:                     }
4648:                 }
4649:             }
4650:         }
4651:
4652:         return ret;
4653:     },
4654:
4655:     has: function( target ) {
4656:         ///    <summary>
4657:         ///        Reduce the set of matched elements to those that have a descendant that matches the
4658:         ///        selector or DOM element.
4659:         ///    </summary>
4660:         ///    <param name="target" type="String">
4661:         ///        A string containing a selector expression to match elements against.
4662:         ///    </param>
4663:         ///    <returns type="jQuery" />
4664:
4665:         var targets = jQuery( target );
4666:         return this.filter(function() {
4667:             for ( var i = 0, l = targets.length; i < l; i++ ) {
4668:                 if ( jQuery.contains( this, targets[i] ) ) {
4669:                     return true;
4670:                 }
4671:             }
4672:         });
4673:     },
4674:
4675:     not: function( selector ) {
4676:         ///    <summary>
4677:         ///        Removes any elements inside the array of elements from the set
4678:         ///        of matched elements. This method is used to remove one or more
4679:         ///        elements from a jQuery object.
4680:         ///        Part of DOM/Traversing
4681:         ///    </summary>
4682:         ///    <param name="selector" type="jQuery">
4683:         ///        A set of elements to remove from the jQuery set of matched elements.
4684:         ///    </param>
4685:         ///    <returns type="jQuery" />
4686:
4687:         return this.pushStack( winnow(this, selector, false), "not", selector);
4688:     },
4689:
4690:     filter: function( selector ) {
4691:         ///    <summary>
4692:         ///        Removes all elements from the set of matched elements that do not
4693:         ///        pass the specified filter. This method is used to narrow down
4694:         ///        the results of a search.
4695:         ///        })
4696:         ///        Part of DOM/Traversing
4697:         ///    </summary>
4698:         ///    <returns type="jQuery" />
4699:         ///    <param name="selector" type="Function">
4700:         ///        A function to use for filtering
4701:         ///    </param>
4702:         ///    <returns type="jQuery" />
4703:
4704:         return this.pushStack( winnow(this, selector, true), "filter", selector );
4705:     },
4706:     
4707:     is: function( selector ) {
4708:         ///    <summary>
4709:         ///        Checks the current selection against an expression and returns true,
4710:         ///        if at least one element of the selection fits the given expression.
4711:         ///        Does return false, if no element fits or the expression is not valid.
4712:         ///        filter(String) is used internally, therefore all rules that apply there
4713:         ///        apply here, too.
4714:         ///        Part of DOM/Traversing
4715:         ///    </summary>
4716:         ///    <returns type="Boolean" />
4717:         ///    <param name="expr" type="String">
4718:         ///         The expression with which to filter
4719:         ///    </param>
4720:
4721:         return !!selector && jQuery.filter( selector, this ).length > 0;
4722:     },
4723:
4724:     closest: function( selectors, context ) {
4725:         ///    <summary>
4726:         ///        Get a set of elements containing the closest parent element that matches the specified selector, the starting element included.
4727:         ///    </summary>
4728:         ///    <param name="selectors" type="String">
4729:         ///        A string containing a selector expression to match elements against.
4730:         ///    </param>
4731:         ///    <param name="context" type="Element">
4732:         ///        A DOM element within which a matching element may be found. If no context is passed
4733:         ///        in then the context of the jQuery set will be used instead.
4734:         ///    </param>
4735:         ///    <returns type="jQuery" />
4736:
4737:         if ( jQuery.isArray( selectors ) ) {
4738:             var ret = [], cur = this[0], match, matches = {}, selector;
4739:
4740:             if ( cur && selectors.length ) {
4741:                 for ( var i = 0, l = selectors.length; i < l; i++ ) {
4742:                     selector = selectors[i];
4743:
4744:                     if ( !matches[selector] ) {
4745:                         matches[selector] = jQuery.expr.match.POS.test( selector ) ?
4746:                             jQuery( selector, context || this.context ) :
4747:                             selector;
4748:                     }
4749:                 }
4750:
4751:                 while ( cur && cur.ownerDocument && cur !== context ) {
4752:                     for ( selector in matches ) {
4753:                         match = matches[selector];
4754:
4755:                         if ( match.jquery ? match.index(cur) > -1 : jQuery(cur).is(match) ) {
4756:                             ret.push({ selector: selector, elem: cur });
4757:                             delete matches[selector];
4758:                         }
4759:                     }
4760:                     cur = cur.parentNode;
4761:                 }
4762:             }
4763:
4764:             return ret;
4765:         }
4766:
4767:         var pos = jQuery.expr.match.POS.test( selectors ) ?
4768:             jQuery( selectors, context || this.context ) : null;
4769:
4770:         return this.map(function( i, cur ) {
4771:             while ( cur && cur.ownerDocument && cur !== context ) {
4772:                 if ( pos ? pos.index(cur) > -1 : jQuery(cur).is(selectors) ) {
4773:                     return cur;
4774:                 }
4775:                 cur = cur.parentNode;
4776:             }
4777:             return null;
4778:         });
4779:     },
4780:     
4781:     // Determine the position of an element within
4782:     // the matched set of elements
4783:     index: function( elem ) {
4784:         ///    <summary>
4785:         ///        Searches every matched element for the object and returns
4786:         ///        the index of the element, if found, starting with zero.
4787:         ///        Returns -1 if the object wasn't found.
4788:         ///        Part of Core
4789:         ///    </summary>
4790:         ///    <returns type="Number" />
4791:         ///    <param name="elem" type="Element">
4792:         ///        Object to search for
4793:         ///    </param>
4794:
4795:         if ( !elem || typeof elem === "string" ) {
4796:             return jQuery.inArray( this[0],
4797:                 // If it receives a string, the selector is used
4798:                 // If it receives nothing, the siblings are used
4799:                 elem ? jQuery( elem ) : this.parent().children() );
4800:         }
4801:         // Locate the position of the desired element
4802:         return jQuery.inArray(
4803:             // If it receives a jQuery object, the first element is used
4804:             elem.jquery ? elem[0] : elem, this );
4805:     },
4806:
4807:     add: function( selector, context ) {
4808:         ///    <summary>
4809:         ///        Adds one or more Elements to the set of matched elements.
4810:         ///        Part of DOM/Traversing
4811:         ///    </summary>
4812:         ///    <param name="selector" type="String">
4813:         ///        A string containing a selector expression to match additional elements against.
4814:         ///    </param>
4815:         ///    <param name="context" type="Element">
4816:         ///        Add some elements rooted against the specified context.
4817:         ///    </param>
4818:         ///    <returns type="jQuery" />
4819:
4820:         var set = typeof selector === "string" ?
4821:                 jQuery( selector, context || this.context ) :
4822:                 jQuery.makeArray( selector ),
4823:             all = jQuery.merge( this.get(), set );
4824:
4825:         return this.pushStack( isDisconnected( set[0] ) || isDisconnected( all[0] ) ?
4826:             all :
4827:             jQuery.unique( all ) );
4828:     },
4829:
4830:     andSelf: function() {
4831:         ///    <summary>
4832:         ///        Adds the previous selection to the current selection.
4833:         ///    </summary>
4834:         ///    <returns type="jQuery" />
4835:
4836:         return this.add( this.prevObject );
4837:     }
4838: });
4839:
4840: // A painfully simple check to see if an element is disconnected
4841: // from a document (should be improved, where feasible).
4842: function isDisconnected( node ) {
4843:     return !node || !node.parentNode || node.parentNode.nodeType === 11;
4844: }
4845:
4846: jQuery.each({
4847:     parent: function( elem ) {
4848:         var parent = elem.parentNode;
4849:         return parent && parent.nodeType !== 11 ? parent : null;
4850:     },
4851:     parents: function( elem ) {
4852:         return jQuery.dir( elem, "parentNode" );
4853:     },
4854:     next: function( elem ) {
4855:         return jQuery.nth( elem, 2, "nextSibling" );
4856:     },
4857:     prev: function( elem ) {
4858:         return jQuery.nth( elem, 2, "previousSibling" );
4859:     },
4860:     nextAll: function( elem ) {
4861:         return jQuery.dir( elem, "nextSibling" );
4862:     },
4863:     prevAll: function( elem ) {
4864:         return jQuery.dir( elem, "previousSibling" );
4865:     },
4866:     siblings: function( elem ) {
4867:         return jQuery.sibling( elem.parentNode.firstChild, elem );
4868:     },
4869:     children: function( elem ) {
4870:         return jQuery.sibling( elem.firstChild );
4871:     },
4872:     contents: function( elem ) {
4873:         return jQuery.nodeName( elem, "iframe" ) ?
4874:             elem.contentDocument || elem.contentWindow.document :
4875:             jQuery.makeArray( elem.childNodes );
4876:     }
4877: }, function( name, fn ) {
4878:     jQuery.fn[ name ] = function( until, selector ) {
4879:         var ret = jQuery.map( this, fn, until );
4880:         
4881:         if ( !runtil.test( name ) ) {
4882:             selector = until;
4883:         }
4884:
4885:         if ( selector && typeof selector === "string" ) {
4886:             ret = jQuery.filter( selector, ret );
4887:         }
4888:
4889:         ret = this.length > 1 ? jQuery.unique( ret ) : ret;
4890:
4891:         if ( (this.length > 1 || rmultiselector.test( selector )) && rparentsprev.test( name ) ) {
4892:             ret = ret.reverse();
4893:         }
4894:
4895:         return this.pushStack( ret, name, slice.call(arguments).join(",") );
4896:     };
4897: });
4898:
4899: jQuery.fn[ "parentsUntil" ] = function( until, selector ) {
4900:     ///    <summary>
4901:     ///        Get the ancestors of each element in the current set of matched elements, up to but not
4902:     ///        including the element matched by the selector.
4903:     ///    </summary>
4904:     ///    <param name="until" type="String">
4905:     ///        A string containing a selector expression to indicate where to stop matching ancestor
4906:     ///        elements.
4907:     ///    </param>
4908:     ///    <returns type="jQuery" />
4909:
4910:     var fn = function( elem, i, until ) {
4911:         return jQuery.dir( elem, "parentNode", until );
4912:     }
4913:
4914:     var ret = jQuery.map( this, fn, until );
4915:     
4916:     if ( !runtil.test( "parentsUntil" ) ) {
4917:         selector = until;
4918:     }
4919:
4920:     if ( selector && typeof selector === "string" ) {
4921:         ret = jQuery.filter( selector, ret );
4922:     }
4923:
4924:     ret = this.length > 1 ? jQuery.unique( ret ) : ret;
4925:
4926:     if ( (this.length > 1 || rmultiselector.test( selector )) && rparentsprev.test( "parentsUntil" ) ) {
4927:         ret = ret.reverse();
4928:     }
4929:
4930:     return this.pushStack( ret, "parentsUntil", slice.call(arguments).join(",") );
4931: };
4932:
4933: jQuery.fn[ "nextUntil" ] = function( until, selector ) {
4934:     ///    <summary>
4935:     ///        Get all following siblings of each element up to but not including the element matched
4936:     ///        by the selector.
4937:     ///    </summary>
4938:     ///    <param name="until" type="String">
4939:     ///        A string containing a selector expression to indicate where to stop matching following
4940:     ///        sibling elements.
4941:     ///    </param>
4942:     ///    <returns type="jQuery" />
4943:
4944:     var fn = function( elem, i, until ) {
4945:         return jQuery.dir( elem, "nextSibling", until );
4946:     }
4947:
4948:     var ret = jQuery.map( this, fn, until );
4949:     
4950:     if ( !runtil.test( "nextUntil" ) ) {
4951:         selector = until;
4952:     }
4953:
4954:     if ( selector && typeof selector === "string" ) {
4955:         ret = jQuery.filter( selector, ret );
4956:     }
4957:
4958:     ret = this.length > 1 ? jQuery.unique( ret ) : ret;
4959:
4960:     if ( (this.length > 1 || rmultiselector.test( selector )) && rparentsprev.test( "nextUntil" ) ) {
4961:         ret = ret.reverse();
4962:     }
4963:
4964:     return this.pushStack( ret, "nextUntil", slice.call(arguments).join(",") );
4965: };
4966:
4967: jQuery.fn[ "prevUntil" ] = function( until, selector ) {
4968:     ///    <summary>
4969:     ///        Get all preceding siblings of each element up to but not including the element matched
4970:     ///        by the selector.
4971:     ///    </summary>
4972:     ///    <param name="until" type="String">
4973:     ///        A string containing a selector expression to indicate where to stop matching preceding
4974:     ///        sibling elements.
4975:     ///    </param>
4976:     ///    <returns type="jQuery" />
4977:
4978:     var fn = function( elem, i, until ) {
4979:         return jQuery.dir( elem, "previousSibling", until );
4980:     }
4981:
4982:     var ret = jQuery.map( this, fn, until );
4983:     
4984:     if ( !runtil.test( "prevUntil" ) ) {
4985:         selector = until;
4986:     }
4987:
4988:     if ( selector && typeof selector === "string" ) {
4989:         ret = jQuery.filter( selector, ret );
4990:     }
4991:
4992:     ret = this.length > 1 ? jQuery.unique( ret ) : ret;
4993:
4994:     if ( (this.length > 1 || rmultiselector.test( selector )) && rparentsprev.test( "prevUntil" ) ) {
4995:         ret = ret.reverse();
4996:     }
4997:
4998:     return this.pushStack( ret, "prevUntil", slice.call(arguments).join(",") );
4999: };
5000:
5001: jQuery.extend({
5002:     filter: function( expr, elems, not ) {
5003:         if ( not ) {
5004:             expr = ":not(" + expr + ")";
5005:         }
5006:
5007:         return jQuery.find.matches(expr, elems);
5008:     },
5009:     
5010:     dir: function( elem, dir, until ) {
5011:         ///    <summary>
5012:         ///        This member is internal only.
5013:         ///    </summary>
5014:         ///    <private />
5015:
5016:         var matched = [], cur = elem[dir];
5017:         while ( cur && cur.nodeType !== 9 && (until === undefined || cur.nodeType !== 1 || !jQuery( cur ).is( until )) ) {
5018:             if ( cur.nodeType === 1 ) {
5019:                 matched.push( cur );
5020:             }
5021:             cur = cur[dir];
5022:         }
5023:         return matched;
5024:     },
5025:
5026:     nth: function( cur, result, dir, elem ) {
5027:         ///    <summary>
5028:         ///        This member is internal only.
5029:         ///    </summary>
5030:         ///    <private />
5031:
5032:         result = result || 1;
5033:         var num = 0;
5034:
5035:         for ( ; cur; cur = cur[dir] ) {
5036:             if ( cur.nodeType === 1 && ++num === result ) {
5037:                 break;
5038:             }
5039:         }
5040:
5041:         return cur;
5042:     },
5043:
5044:     sibling: function( n, elem ) {
5045:         ///    <summary>
5046:         ///        This member is internal only.
5047:         ///    </summary>
5048:         ///    <private />
5049:
5050:         var r = [];
5051:
5052:         for ( ; n; n = n.nextSibling ) {
5053:             if ( n.nodeType === 1 && n !== elem ) {
5054:                 r.push( n );
5055:             }
5056:         }
5057:
5058:         return r;
5059:     }
5060: });
5061: var rinlinejQuery = / jQuery\d+="(?:\d+|null)"/g,
5062:     rleadingWhitespace = /^\s+/,
5063:     rxhtmlTag = /(<([\w:]+)[^>]*?)\/>/g,
5064:     rselfClosing = /^(?:area|br|col|embed|hr|img|input|link|meta|param)$/i,
5065:     rtagName = /<([\w:]+)/,
5066:     rtbody = /<tbody/i,
5067:     rhtml = /<|&\w+;/,
5068:     rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i, // checked="checked" or checked (html5)
5069:     fcloseTag = function( all, front, tag ) {
5070:         return rselfClosing.test( tag ) ?
5071:             all :
5072:             front + "></" + tag + ">";
5073:     },
5074:     wrapMap = {
5075:         option: [ 1, "<select multiple='multiple'>", "</select>" ],
5076:         legend: [ 1, "<fieldset>", "</fieldset>" ],
5077:         thead: [ 1, "<table>", "</table>" ],
5078:         tr: [ 2, "<table><tbody>", "</tbody></table>" ],
5079:         td: [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ],
5080:         col: [ 2, "<table><tbody></tbody><colgroup>", "</colgroup></table>" ],
5081:         area: [ 1, "<map>", "</map>" ],
5082:         _default: [ 0, "", "" ]
5083:     };
5084:
5085: wrapMap.optgroup = wrapMap.option;
5086: wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead;
5087: wrapMap.th = wrapMap.td;
5088:
5089: // IE can't serialize <link> and <script> tags normally
5090: if ( !jQuery.support.htmlSerialize ) {
5091:     wrapMap._default = [ 1, "div<div>", "</div>" ];
5092: }
5093:
5094: jQuery.fn.extend({
5095:     text: function( text ) {
5096:         ///    <summary>
5097:         ///        Set the text contents of all matched elements.
5098:         ///        Similar to html(), but escapes HTML (replace "<" and ">" with their
5099:         ///        HTML entities).
5100:         ///        Part of DOM/Attributes
5101:         ///    </summary>
5102:         ///    <returns type="jQuery" />
5103:         ///    <param name="text" type="String">
5104:         ///        The text value to set the contents of the element to.
5105:         ///    </param>
5106:
5107:         if ( jQuery.isFunction(text) ) {
5108:             return this.each(function(i) {
5109:                 var self = jQuery(this);
5110:                 self.text( text.call(this, i, self.text()) );
5111:             });
5112:         }
5113:
5114:         if ( typeof text !== "object" && text !== undefined ) {
5115:             return this.empty().append( (this[0] && this[0].ownerDocument || document).createTextNode( text ) );
5116:         }
5117:
5118:         return jQuery.getText( this );
5119:     },
5120:
5121:     wrapAll: function( html ) {
5122:         ///    <summary>
5123:         ///        Wrap all matched elements with a structure of other elements.
5124:         ///        This wrapping process is most useful for injecting additional
5125:         ///        stucture into a document, without ruining the original semantic
5126:         ///        qualities of a document.
5127:         ///        This works by going through the first element
5128:         ///        provided and finding the deepest ancestor element within its
5129:         ///        structure - it is that element that will en-wrap everything else.
5130:         ///        This does not work with elements that contain text. Any necessary text
5131:         ///        must be added after the wrapping is done.
5132:         ///        Part of DOM/Manipulation
5133:         ///    </summary>
5134:         ///    <returns type="jQuery" />
5135:         ///    <param name="html" type="Element">
5136:         ///        A DOM element that will be wrapped around the target.
5137:         ///    </param>
5138:
5139:         if ( jQuery.isFunction( html ) ) {
5140:             return this.each(function(i) {
5141:                 jQuery(this).wrapAll( html.call(this, i) );
5142:             });
5143:         }
5144:
5145:         if ( this[0] ) {
5146:             // The elements to wrap the target around
5147:             var wrap = jQuery( html, this[0].ownerDocument ).eq(0).clone(true);
5148:
5149:             if ( this[0].parentNode ) {
5150:                 wrap.insertBefore( this[0] );
5151:             }
5152:
5153:             wrap.map(function() {
5154:                 var elem = this;
5155:
5156:                 while ( elem.firstChild && elem.firstChild.nodeType === 1 ) {
5157:                     elem = elem.firstChild;
5158:                 }
5159:
5160:                 return elem;
5161:             }).append(this);
5162:         }
5163:
5164:         return this;
5165:     },
5166:
5167:     wrapInner: function( html ) {
5168:         ///    <summary>
5169:         ///        Wraps the inner child contents of each matched elemenht (including text nodes) with an HTML structure.
5170:         ///    </summary>
5171:         ///    <param name="html" type="String">
5172:         ///        A string of HTML or a DOM element that will be wrapped around the target contents.
5173:         ///    </param>
5174:         ///    <returns type="jQuery" />
5175:
5176:         if ( jQuery.isFunction( html ) ) {
5177:             return this.each(function(i) {
5178:                 jQuery(this).wrapInner( html.call(this, i) );
5179:             });
5180:         }
5181:
5182:         return this.each(function() {
5183:             var self = jQuery( this ), contents = self.contents();
5184:
5185:             if ( contents.length ) {
5186:                 contents.wrapAll( html );
5187:
5188:             } else {
5189:                 self.append( html );
5190:             }
5191:         });
5192:     },
5193:
5194:     wrap: function( html ) {
5195:         ///    <summary>
5196:         ///        Wrap all matched elements with a structure of other elements.
5197:         ///        This wrapping process is most useful for injecting additional
5198:         ///        stucture into a document, without ruining the original semantic
5199:         ///        qualities of a document.
5200:         ///        This works by going through the first element
5201:         ///        provided and finding the deepest ancestor element within its
5202:         ///        structure - it is that element that will en-wrap everything else.
5203:         ///        This does not work with elements that contain text. Any necessary text
5204:         ///        must be added after the wrapping is done.
5205:         ///        Part of DOM/Manipulation
5206:         ///    </summary>
5207:         ///    <returns type="jQuery" />
5208:         ///    <param name="html" type="Element">
5209:         ///        A DOM element that will be wrapped around the target.
5210:         ///    </param>
5211:
5212:         return this.each(function() {
5213:             jQuery( this ).wrapAll( html );
5214:         });
5215:     },
5216:
5217:     unwrap: function() {
5218:         ///    <summary>
5219:         ///        Remove the parents of the set of matched elements from the DOM, leaving the matched
5220:         ///        elements in their place.
5221:         ///    </summary>
5222:         ///    <returns type="jQuery" />
5223:         return this.parent().each(function() {
5224:             if ( !jQuery.nodeName( this, "body" ) ) {
5225:                 jQuery( this ).replaceWith( this.childNodes );
5226:             }
5227:         }).end();
5228:     },
5229:
5230:     append: function() {
5231:         ///    <summary>
5232:         ///        Append content to the inside of every matched element.
5233:         ///        This operation is similar to doing an appendChild to all the
5234:         ///        specified elements, adding them into the document.
5235:         ///        Part of DOM/Manipulation
5236:         ///    </summary>
5237:         ///    <returns type="jQuery" />
5238:
5239:         return this.domManip(arguments, true, function( elem ) {
5240:             if ( this.nodeType === 1 ) {
5241:                 this.appendChild( elem );
5242:             }
5243:         });
5244:     },
5245:
5246:     prepend: function() {
5247:         ///    <summary>
5248:         ///        Prepend content to the inside of every matched element.
5249:         ///        This operation is the best way to insert elements
5250:         ///        inside, at the beginning, of all matched elements.
5251:         ///        Part of DOM/Manipulation
5252:         ///    </summary>
5253:         ///    <returns type="jQuery" />
5254:
5255:         return this.domManip(arguments, true, function( elem ) {
5256:             if ( this.nodeType === 1 ) {
5257:                 this.insertBefore( elem, this.firstChild );
5258:             }
5259:         });
5260:     },
5261:
5262:     before: function() {
5263:         ///    <summary>
5264:         ///        Insert content before each of the matched elements.
5265:         ///        Part of DOM/Manipulation
5266:         ///    </summary>
5267:         ///    <returns type="jQuery" />
5268:
5269:         if ( this[0] && this[0].parentNode ) {
5270:             return this.domManip(arguments, false, function( elem ) {
5271:                 this.parentNode.insertBefore( elem, this );
5272:             });
5273:         } else if ( arguments.length ) {
5274:             var set = jQuery(arguments[0]);
5275:             set.push.apply( set, this.toArray() );
5276:             return this.pushStack( set, "before", arguments );
5277:         }
5278:     },
5279:
5280:     after: function() {
5281:         ///    <summary>
5282:         ///        Insert content after each of the matched elements.
5283:         ///        Part of DOM/Manipulation
5284:         ///    </summary>
5285:         ///    <returns type="jQuery" />
5286:
5287:         if ( this[0] && this[0].parentNode ) {
5288:             return this.domManip(arguments, false, function( elem ) {
5289:                 this.parentNode.insertBefore( elem, this.nextSibling );
5290:             });
5291:         } else if ( arguments.length ) {
5292:             var set = this.pushStack( this, "after", arguments );
5293:             set.push.apply( set, jQuery(arguments[0]).toArray() );
5294:             return set;
5295:         }
5296:     },
5297:
5298:     clone: function( events ) {
5299:         ///    <summary>
5300:         ///        Clone matched DOM Elements and select the clones.
5301:         ///        This is useful for moving copies of the elements to another
5302:         ///        location in the DOM.
5303:         ///        Part of DOM/Manipulation
5304:         ///    </summary>
5305:         ///    <returns type="jQuery" />
5306:         ///    <param name="deep" type="Boolean" optional="true">
5307:         ///        (Optional) Set to false if you don't want to clone all descendant nodes, in addition to the element itself.
5308:         ///    </param>
5309:
5310:         // Do the clone
5311:         var ret = this.map(function() {
5312:             if ( !jQuery.support.noCloneEvent && !jQuery.isXMLDoc(this) ) {
5313:                 // IE copies events bound via attachEvent when
5314:                 // using cloneNode. Calling detachEvent on the
5315:                 // clone will also remove the events from the orignal
5316:                 // In order to get around this, we use innerHTML.
5317:                 // Unfortunately, this means some modifications to
5318:                 // attributes in IE that are actually only stored
5319:                 // as properties will not be copied (such as the
5320:                 // the name attribute on an input).
5321:                 var html = this.outerHTML, ownerDocument = this.ownerDocument;
5322:                 if ( !html ) {
5323:                     var div = ownerDocument.createElement("div");
5324:                     div.appendChild( this.cloneNode(true) );
5325:                     html = div.innerHTML;
5326:                 }
5327:
5328:                 return jQuery.clean([html.replace(rinlinejQuery, "")
5329:                     .replace(rleadingWhitespace, "")], ownerDocument)[0];
5330:             } else {
5331:                 return this.cloneNode(true);
5332:             }
5333:         });
5334:
5335:         // Copy the events from the original to the clone
5336:         if ( events === true ) {
5337:             cloneCopyEvent( this, ret );
5338:             cloneCopyEvent( this.find("*"), ret.find("*") );
5339:         }
5340:
5341:         // Return the cloned set
5342:         return ret;
5343:     },
5344:
5345:     html: function( value ) {
5346:         ///    <summary>
5347:         ///        Set the html contents of every matched element.
5348:         ///        This property is not available on XML documents.
5349:         ///        Part of DOM/Attributes
5350:         ///    </summary>
5351:         ///    <returns type="jQuery" />
5352:         ///    <param name="value" type="String">
5353:         ///        A string of HTML to set as the content of each matched element.
5354:         ///    </param>
5355:
5356:         if ( value === undefined ) {
5357:             return this[0] && this[0].nodeType === 1 ?
5358:                 this[0].innerHTML.replace(rinlinejQuery, "") :
5359:                 null;
5360:
5361:         // See if we can take a shortcut and just use innerHTML
5362:         } else if ( typeof value === "string" && !/<script/i.test( value ) &&
5363:             (jQuery.support.leadingWhitespace || !rleadingWhitespace.test( value )) &&
5364:             !wrapMap[ (rtagName.exec( value ) || ["", ""])[1].toLowerCase() ] ) {
5365:
5366:             value = value.replace(rxhtmlTag, fcloseTag);
5367:
5368:             try {
5369:                 for ( var i = 0, l = this.length; i < l; i++ ) {
5370:                     // Remove element nodes and prevent memory leaks
5371:                     if ( this[i].nodeType === 1 ) {
5372:                         jQuery.cleanData( this[i].getElementsByTagName("*") );
5373:                         this[i].innerHTML = value;
5374:                     }
5375:                 }
5376:
5377:             // If using innerHTML throws an exception, use the fallback method
5378:             } catch(e) {
5379:                 this.empty().append( value );
5380:             }
5381:
5382:         } else if ( jQuery.isFunction( value ) ) {
5383:             this.each(function(i){
5384:                 var self = jQuery(this), old = self.html();
5385:                 self.empty().append(function(){
5386:                     return value.call( this, i, old );
5387:                 });
5388:             });
5389:
5390:         } else {
5391:             this.empty().append( value );
5392:         }
5393:
5394:         return this;
5395:     },
5396:
5397:     replaceWith: function( value ) {
5398:         ///    <summary>
5399:         ///        Replaces all matched element with the specified HTML or DOM elements.
5400:         ///    </summary>
5401:         ///    <param name="value" type="Object">
5402:         ///        The content to insert. May be an HTML string, DOM element, or jQuery object.
5403:         ///    </param>
5404:         ///    <returns type="jQuery">The element that was just replaced.</returns>
5405:
5406:         if ( this[0] && this[0].parentNode ) {
5407:             // Make sure that the elements are removed from the DOM before they are inserted
5408:             // this can help fix replacing a parent with child elements
5409:             if ( !jQuery.isFunction( value ) ) {
5410:                 value = jQuery( value ).detach();
5411:
5412:             } else {
5413:                 return this.each(function(i) {
5414:                     var self = jQuery(this), old = self.html();
5415:                     self.replaceWith( value.call( this, i, old ) );
5416:                 });
5417:             }
5418:
5419:             return this.each(function() {
5420:                 var next = this.nextSibling, parent = this.parentNode;
5421:
5422:                 jQuery(this).remove();
5423:
5424:                 if ( next ) {
5425:                     jQuery(next).before( value );
5426:                 } else {
5427:                     jQuery(parent).append( value );
5428:                 }
5429:             });
5430:         } else {
5431:             return this.pushStack( jQuery(jQuery.isFunction(value) ? value() : value), "replaceWith", value );
5432:         }
5433:     },
5434:
5435:     detach: function( selector ) {
5436:         ///    <summary>
5437:         ///        Remove the set of matched elements from the DOM.
5438:         ///    </summary>
5439:         ///    <param name="selector" type="String">
5440:         ///        A selector expression that filters the set of matched elements to be removed.
5441:         ///    </param>
5442:         ///    <returns type="jQuery" />
5443:
5444:         return this.remove( selector, true );
5445:     },
5446:
5447:     domManip: function( args, table, callback ) {
5448:         ///    <param name="args" type="Array">
5449:         ///         Args
5450:         ///    </param>
5451:         ///    <param name="table" type="Boolean">
5452:         ///         Insert TBODY in TABLEs if one is not found.
5453:         ///    </param>
5454:         ///    <param name="dir" type="Number">
5455:         ///         If dir<0, process args in reverse order.
5456:         ///    </param>
5457:         ///    <param name="fn" type="Function">
5458:         ///         The function doing the DOM manipulation.
5459:         ///    </param>
5460:         ///    <returns type="jQuery" />
5461:         ///    <summary>
5462:         ///        Part of Core
5463:         ///    </summary>
5464:
5465:         var results, first, value = args[0], scripts = [];
5466:
5467:         // We can't cloneNode fragments that contain checked, in WebKit
5468:         if ( !jQuery.support.checkClone && arguments.length === 3 && typeof value === "string" && rchecked.test( value ) ) {
5469:             return this.each(function() {
5470:                 jQuery(this).domManip( args, table, callback, true );
5471:             });
5472:         }
5473:
5474:         if ( jQuery.isFunction(value) ) {
5475:             return this.each(function(i) {
5476:                 var self = jQuery(this);
5477:                 args[0] = value.call(this, i, table ? self.html() : undefined);
5478:                 self.domManip( args, table, callback );
5479:             });
5480:         }
5481:
5482:         if ( this[0] ) {
5483:             // If we're in a fragment, just use that instead of building a new one
5484:             if ( args[0] && args[0].parentNode && args[0].parentNode.nodeType === 11 ) {
5485:                 results = { fragment: args[0].parentNode };
5486:             } else {
5487:                 results = buildFragment( args, this, scripts );
5488:             }
5489:
5490:             first = results.fragment.firstChild;
5491:
5492:             if ( first ) {
5493:                 table = table && jQuery.nodeName( first, "tr" );
5494:
5495:                 for ( var i = 0, l = this.length; i < l; i++ ) {
5496:                     callback.call(
5497:                         table ?
5498:                             root(this[i], first) :
5499:                             this[i],
5500:                         results.cacheable || this.length > 1 || i > 0 ?
5501:                             results.fragment.cloneNode(true) :
5502:                             results.fragment
5503:                     );
5504:                 }
5505:             }
5506:
5507:             if ( scripts ) {
5508:                 jQuery.each( scripts, evalScript );
5509:             }
5510:         }
5511:
5512:         return this;
5513:
5514:         function root( elem, cur ) {
5515:             return jQuery.nodeName(elem, "table") ?
5516:                 (elem.getElementsByTagName("tbody")[0] ||
5517:                 elem.appendChild(elem.ownerDocument.createElement("tbody"))) :
5518:                 elem;
5519:         }
5520:     }
5521: });
5522:
5523: function cloneCopyEvent(orig, ret) {
5524:     var i = 0;
5525:
5526:     ret.each(function() {
5527:         if ( this.nodeName !== (orig[i] && orig[i].nodeName) ) {
5528:             return;
5529:         }
5530:
5531:         var oldData = jQuery.data( orig[i++] ), curData = jQuery.data( this, oldData ), events = oldData && oldData.events;
5532:
5533:         if ( events ) {
5534:             delete curData.handle;
5535:             curData.events = {};
5536:
5537:             for ( var type in events ) {
5538:                 for ( var handler in events[ type ] ) {
5539:                     jQuery.event.add( this, type, events[ type ][ handler ], events[ type ][ handler ].data );
5540:                 }
5541:             }
5542:         }
5543:     });
5544: }
5545:
5546: function buildFragment( args, nodes, scripts ) {
5547:     var fragment, cacheable, cacheresults, doc;
5548:
5549:     // webkit does not clone 'checked' attribute of radio inputs on cloneNode, so don't cache if string has a checked
5550:     if ( args.length === 1 && typeof args[0] === "string" && args[0].length < 512 && args[0].indexOf("<option") < 0 && (jQuery.support.checkClone || !rchecked.test( args[0] )) ) {
5551:         cacheable = true;
5552:         cacheresults = jQuery.fragments[ args[0] ];
5553:         if ( cacheresults ) {
5554:             if ( cacheresults !== 1 ) {
5555:                 fragment = cacheresults;
5556:             }
5557:         }
5558:     }
5559:
5560:     if ( !fragment ) {
5561:         doc = (nodes && nodes[0] ? nodes[0].ownerDocument || nodes[0] : document);
5562:         fragment = doc.createDocumentFragment();
5563:         jQuery.clean( args, doc, fragment, scripts );
5564:     }
5565:
5566:     if ( cacheable ) {
5567:         jQuery.fragments[ args[0] ] = cacheresults ? fragment : 1;
5568:     }
5569:
5570:     return { fragment: fragment, cacheable: cacheable };
5571: }
5572:
5573: jQuery.fragments = {};
5574:
5575: //    jQuery.each({
5576: //        appendTo: "append",
5577: //        prependTo: "prepend",
5578: //        insertBefore: "before",
5579: //        insertAfter: "after",
5580: //        replaceAll: "replaceWith"
5581: //    }, function( name, original ) {
5582: //        jQuery.fn[ name ] = function( selector ) {
5583: //            var ret = [], insert = jQuery( selector );
5584:
5585: //            for ( var i = 0, l = insert.length; i < l; i++ ) {
5586: //                var elems = (i > 0 ? this.clone(true) : this).get();
5587: //                jQuery.fn[ original ].apply( jQuery(insert[i]), elems );
5588: //                ret = ret.concat( elems );
5589: //            }
5590: //            return this.pushStack( ret, name, insert.selector );
5591: //        };
5592: //    });
5593:
5594: jQuery.fn[ "appendTo" ] = function( selector ) {
5595:     ///    <summary>
5596:     ///        Append all of the matched elements to another, specified, set of elements.
5597:     ///        As of jQuery 1.3.2, returns all of the inserted elements.
5598:     ///        This operation is, essentially, the reverse of doing a regular
5599:     ///        $(A).append(B), in that instead of appending B to A, you're appending
5600:     ///        A to B.
5601:     ///    </summary>
5602:     ///    <param name="selector" type="Selector">
5603:     ///         target to which the content will be appended.
5604:     ///    </param>
5605:     ///    <returns type="jQuery" />
5606:
5607:     var ret = [], insert = jQuery( selector );
5608:
5609:     for ( var i = 0, l = insert.length; i < l; i++ ) {
5610:         var elems = (i > 0 ? this.clone(true) : this).get();
5611:         jQuery.fn[ "append" ].apply( jQuery(insert[i]), elems );
5612:         ret = ret.concat( elems );
5613:     }
5614:     return this.pushStack( ret, "appendTo", insert.selector );
5615: };
5616:
5617: jQuery.fn[ "prependTo" ] = function( selector ) {
5618:     ///    <summary>
5619:     ///        Prepend all of the matched elements to another, specified, set of elements.
5620:     ///        As of jQuery 1.3.2, returns all of the inserted elements.
5621:     ///        This operation is, essentially, the reverse of doing a regular
5622:     ///        $(A).prepend(B), in that instead of prepending B to A, you're prepending
5623:     ///        A to B.
5624:     ///    </summary>
5625:     ///    <param name="selector" type="Selector">
5626:     ///         target to which the content will be appended.
5627:     ///    </param>
5628:     ///    <returns type="jQuery" />
5629:
5630:     var ret = [], insert = jQuery( selector );
5631:
5632:     for ( var i = 0, l = insert.length; i < l; i++ ) {
5633:         var elems = (i > 0 ? this.clone(true) : this).get();
5634:         jQuery.fn[ "prepend" ].apply( jQuery(insert[i]), elems );
5635:         ret = ret.concat( elems );
5636:     }
5637:     return this.pushStack( ret, "prependTo", insert.selector );
5638: };
5639:
5640: jQuery.fn[ "insertBefore" ] = function( selector ) {
5641:     ///    <summary>
5642:     ///        Insert all of the matched elements before another, specified, set of elements.
5643:     ///        As of jQuery 1.3.2, returns all of the inserted elements.
5644:     ///        This operation is, essentially, the reverse of doing a regular
5645:     ///        $(A).before(B), in that instead of inserting B before A, you're inserting
5646:     ///        A before B.
5647:     ///    </summary>
5648:     ///    <param name="content" type="String">
5649:     ///         Content after which the selected element(s) is inserted.
5650:     ///    </param>
5651:     ///    <returns type="jQuery" />
5652:
5653:     var ret = [], insert = jQuery( selector );
5654:
5655:     for ( var i = 0, l = insert.length; i < l; i++ ) {
5656:         var elems = (i > 0 ? this.clone(true) : this).get();
5657:         jQuery.fn[ "before" ].apply( jQuery(insert[i]), elems );
5658:         ret = ret.concat( elems );
5659:     }
5660:     return this.pushStack( ret, "insertBefore", insert.selector );
5661: };
5662:
5663: jQuery.fn[ "insertAfter" ] = function( selector ) {
5664:     ///    <summary>
5665:     ///        Insert all of the matched elements after another, specified, set of elements.
5666:     ///        As of jQuery 1.3.2, returns all of the inserted elements.
5667:     ///        This operation is, essentially, the reverse of doing a regular
5668:     ///        $(A).after(B), in that instead of inserting B after A, you're inserting
5669:     ///        A after B.
5670:     ///    </summary>
5671:     ///    <param name="content" type="String">
5672:     ///         Content after which the selected element(s) is inserted.
5673:     ///    </param>
5674:     ///    <returns type="jQuery" />
5675:
5676:     var ret = [], insert = jQuery( selector );
5677:
5678:     for ( var i = 0, l = insert.length; i < l; i++ ) {
5679:         var elems = (i > 0 ? this.clone(true) : this).get();
5680:         jQuery.fn[ "after" ].apply( jQuery(insert[i]), elems );
5681:         ret = ret.concat( elems );
5682:     }
5683:     return this.pushStack( ret, "insertAfter", insert.selector );
5684: };
5685:
5686: jQuery.fn[ "replaceAll" ] = function( selector ) {
5687:     ///    <summary>
5688:     ///        Replaces the elements matched by the specified selector with the matched elements.
5689:     ///        As of jQuery 1.3.2, returns all of the inserted elements.
5690:     ///    </summary>
5691:     ///    <param name="selector" type="Selector">The elements to find and replace the matched elements with.</param>
5692:     ///    <returns type="jQuery" />
5693:
5694:     var ret = [], insert = jQuery( selector );
5695:
5696:     for ( var i = 0, l = insert.length; i < l; i++ ) {
5697:         var elems = (i > 0 ? this.clone(true) : this).get();
5698:         jQuery.fn[ "replaceWith" ].apply( jQuery(insert[i]), elems );
5699:         ret = ret.concat( elems );
5700:     }
5701:     return this.pushStack( ret, "replaceAll", insert.selector );
5702: };
5703:
5704: jQuery.each({
5705:     // keepData is for internal use only--do not document
5706:     remove: function( selector, keepData ) {
5707:         if ( !selector || jQuery.filter( selector, [ this ] ).length ) {
5708:             if ( !keepData && this.nodeType === 1 ) {
5709:                 jQuery.cleanData( this.getElementsByTagName("*") );
5710:                 jQuery.cleanData( [ this ] );
5711:             }
5712:
5713:             if ( this.parentNode ) {
5714:                  this.parentNode.removeChild( this );
5715:             }
5716:         }
5717:     },
5718:
5719:     empty: function() {
5720:         ///    <summary>
5721:         ///        Removes all child nodes from the set of matched elements.
5722:         ///        Part of DOM/Manipulation
5723:         ///    </summary>
5724:         ///    <returns type="jQuery" />
5725:
5726:         // Remove element nodes and prevent memory leaks
5727:         if ( this.nodeType === 1 ) {
5728:             jQuery.cleanData( this.getElementsByTagName("*") );
5729:         }
5730:
5731:         // Remove any remaining nodes
5732:         while ( this.firstChild ) {
5733:             this.removeChild( this.firstChild );
5734:         }
5735:     }
5736: }, function( name, fn ) {
5737:     jQuery.fn[ name ] = function() {
5738:         return this.each( fn, arguments );
5739:     };
5740: });
5741:
5742: jQuery.extend({
5743:     clean: function( elems, context, fragment, scripts ) {
5744:         ///    <summary>
5745:         ///        This method is internal only.
5746:         ///    </summary>
5747:         ///    <private />
5748:
5749:         context = context || document;
5750:
5751:         // !context.createElement fails in IE with an error but returns typeof 'object'
5752:         if ( typeof context.createElement === "undefined" ) {
5753:             context = context.ownerDocument || context[0] && context[0].ownerDocument || document;
5754:         }
5755:
5756:         var ret = [];
5757:
5758:         jQuery.each(elems, function( i, elem ) {
5759:             if ( typeof elem === "number" ) {
5760:                 elem += "";
5761:             }
5762:
5763:             if ( !elem ) {
5764:                 return;
5765:             }
5766:
5767:             // Convert html string into DOM nodes
5768:             if ( typeof elem === "string" && !rhtml.test( elem ) ) {
5769:                 elem = context.createTextNode( elem );
5770:
5771:             } else if ( typeof elem === "string" ) {
5772:                 // Fix "XHTML"-style tags in all browsers
5773:                 elem = elem.replace(rxhtmlTag, fcloseTag);
5774:
5775:                 // Trim whitespace, otherwise indexOf won't work as expected
5776:                 var tag = (rtagName.exec( elem ) || ["", ""])[1].toLowerCase(),
5777:                     wrap = wrapMap[ tag ] || wrapMap._default,
5778:                     depth = wrap[0],
5779:                     div = context.createElement("div");
5780:
5781:                 // Go to html and back, then peel off extra wrappers
5782:                 div.innerHTML = wrap[1] + elem + wrap[2];
5783:
5784:                 // Move to the right depth
5785:                 while ( depth-- ) {
5786:                     div = div.lastChild;
5787:                 }
5788:
5789:                 // Remove IE's autoinserted <tbody> from table fragments
5790:                 if ( !jQuery.support.tbody ) {
5791:
5792:                     // String was a <table>, *may* have spurious <tbody>
5793:                     var hasBody = rtbody.test(elem),
5794:                         tbody = tag === "table" && !hasBody ?
5795:                             div.firstChild && div.firstChild.childNodes :
5796:
5797:                             // String was a bare <thead> or <tfoot>
5798:                             wrap[1] === "<table>" && !hasBody ?
5799:                                 div.childNodes :
5800:                                 [];
5801:
5802:                     for ( var j = tbody.length - 1; j >= 0 ; --j ) {
5803:                         if ( jQuery.nodeName( tbody[ j ], "tbody" ) && !tbody[ j ].childNodes.length ) {
5804:                             tbody[ j ].parentNode.removeChild( tbody[ j ] );
5805:                         }
5806:                     }
5807:
5808:                 }
5809:
5810:                 // IE completely kills leading whitespace when innerHTML is used
5811:                 if ( !jQuery.support.leadingWhitespace && rleadingWhitespace.test( elem ) ) {
5812:                     div.insertBefore( context.createTextNode( rleadingWhitespace.exec(elem)[0] ), div.firstChild );
5813:                 }
5814:
5815:                 elem = jQuery.makeArray( div.childNodes );
5816:             }
5817:
5818:             if ( elem.nodeType ) {
5819:                 ret.push( elem );
5820:             } else {
5821:                 ret = jQuery.merge( ret, elem );
5822:             }
5823:
5824:         });
5825:
5826:         if ( fragment ) {
5827:             for ( var i = 0; ret[i]; i++ ) {
5828:                 if ( scripts && jQuery.nodeName( ret[i], "script" ) && (!ret[i].type || ret[i].type.toLowerCase() === "text/javascript") ) {
5829:                     scripts.push( ret[i].parentNode ? ret[i].parentNode.removeChild( ret[i] ) : ret[i] );
5830:                 } else {
5831:                     if ( ret[i].nodeType === 1 ) {
5832:                         ret.splice.apply( ret, [i + 1, 0].concat(jQuery.makeArray(ret[i].getElementsByTagName("script"))) );
5833:                     }
5834:                     fragment.appendChild( ret[i] );
5835:                 }
5836:             }
5837:         }
5838:
5839:         return ret;
5840:     },
5841:     
5842:     cleanData: function( elems ) {
5843:         for ( var i = 0, elem, id; (elem = elems[i]) != null; i++ ) {
5844:             jQuery.event.remove( elem );
5845:             jQuery.removeData( elem );
5846:         }
5847:     }
5848: });
5849: // exclude the following css properties to add px
5850: var rexclude = /z-?index|font-?weight|opacity|zoom|line-?height/i,
5851:     ralpha = /alpha\([^)]*\)/,
5852:     ropacity = /opacity=([^)]*)/,
5853:     rfloat = /float/i,
5854:     rdashAlpha = /-([a-z])/ig,
5855:     rupper = /([A-Z])/g,
5856:     rnumpx = /^-?\d+(?:px)?$/i,
5857:     rnum = /^-?\d/,
5858:
5859:     cssShow = { position: "absolute", visibility: "hidden", display:"block" },
5860:     cssWidth = [ "Left", "Right" ],
5861:     cssHeight = [ "Top", "Bottom" ],
5862:
5863:     // cache check for defaultView.getComputedStyle
5864:     getComputedStyle = document.defaultView && document.defaultView.getComputedStyle,
5865:     // normalize float css property
5866:     styleFloat = jQuery.support.cssFloat ? "cssFloat" : "styleFloat",
5867:     fcamelCase = function( all, letter ) {
5868:         return letter.toUpperCase();
5869:     };
5870:
5871: jQuery.fn.css = function( name, value ) {
5872:     ///    <summary>
5873:     ///        Set a single style property to a value, on all matched elements.
5874:     ///        If a number is provided, it is automatically converted into a pixel value.
5875:     ///        Part of CSS
5876:     ///    </summary>
5877:     ///    <returns type="jQuery" />
5878:     ///    <param name="name" type="String">
5879:     ///        A CSS property name.
5880:     ///    </param>
5881:     ///    <param name="value" type="String">
5882:     ///        A value to set for the property.
5883:     ///    </param>
5884:
5885:     return access( this, name, value, true, function( elem, name, value ) {
5886:         if ( value === undefined ) {
5887:             return jQuery.curCSS( elem, name );
5888:         }
5889:         
5890:         if ( typeof value === "number" && !rexclude.test(name) ) {
5891:             value += "px";
5892:         }
5893:
5894:         jQuery.style( elem, name, value );
5895:     });
5896: };
5897:
5898: jQuery.extend({
5899:     style: function( elem, name, value ) {
5900:         // don't set styles on text and comment nodes
5901:         if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 ) {
5902:             return undefined;
5903:         }
5904:
5905:         // ignore negative width and height values #1599
5906:         if ( (name === "width" || name === "height") && parseFloat(value) < 0 ) {
5907:             value = undefined;
5908:         }
5909:
5910:         var style = elem.style || elem, set = value !== undefined;
5911:
5912:         // IE uses filters for opacity
5913:         if ( !jQuery.support.opacity && name === "opacity" ) {
5914:             if ( set ) {
5915:                 // IE has trouble with opacity if it does not have layout
5916:                 // Force it by setting the zoom level
5917:                 style.zoom = 1;
5918:
5919:                 // Set the alpha filter to set the opacity
5920:                 var opacity = parseInt( value, 10 ) + "" === "NaN" ? "" : "alpha(opacity=" + value * 100 + ")";
5921:                 var filter = style.filter || jQuery.curCSS( elem, "filter" ) || "";
5922:                 style.filter = ralpha.test(filter) ? filter.replace(ralpha, opacity) : opacity;
5923:             }
5924:
5925:             return style.filter && style.filter.indexOf("opacity=") >= 0 ?
5926:                 (parseFloat( ropacity.exec(style.filter)[1] ) / 100) + "":
5927:                 "";
5928:         }
5929:
5930:         // Make sure we're using the right name for getting the float value
5931:         if ( rfloat.test( name ) ) {
5932:             name = styleFloat;
5933:         }
5934:
5935:         name = name.replace(rdashAlpha, fcamelCase);
5936:
5937:         if ( set ) {
5938:             style[ name ] = value;
5939:         }
5940:
5941:         return style[ name ];
5942:     },
5943:
5944:     css: function( elem, name, force, extra ) {
5945:         ///    <summary>
5946:         ///        This method is internal only.
5947:         ///    </summary>
5948:         ///    <private />
5949:
5950:         if ( name === "width" || name === "height" ) {
5951:             var val, props = cssShow, which = name === "width" ? cssWidth : cssHeight;
5952:
5953:             function getWH() {
5954:                 val = name === "width" ? elem.offsetWidth : elem.offsetHeight;
5955:
5956:                 if ( extra === "border" ) {
5957:                     return;
5958:                 }
5959:
5960:                 jQuery.each( which, function() {
5961:                     if ( !extra ) {
5962:                         val -= parseFloat(jQuery.curCSS( elem, "padding" + this, true)) || 0;
5963:                     }
5964:
5965:                     if ( extra === "margin" ) {
5966:                         val += parseFloat(jQuery.curCSS( elem, "margin" + this, true)) || 0;
5967:                     } else {
5968:                         val -= parseFloat(jQuery.curCSS( elem, "border" + this + "Width", true)) || 0;
5969:                     }
5970:                 });
5971:             }
5972:
5973:             if ( elem.offsetWidth !== 0 ) {
5974:                 getWH();
5975:             } else {
5976:                 jQuery.swap( elem, props, getWH );
5977:             }
5978:
5979:             return Math.max(0, Math.round(val));
5980:         }
5981:
5982:         return jQuery.curCSS( elem, name, force );
5983:     },
5984:
5985:     curCSS: function( elem, name, force ) {
5986:         ///    <summary>
5987:         ///        This method is internal only.
5988:         ///    </summary>
5989:         ///    <private />
5990:
5991:         var ret, style = elem.style, filter;
5992:
5993:         // IE uses filters for opacity
5994:         if ( !jQuery.support.opacity && name === "opacity" && elem.currentStyle ) {
5995:             ret = ropacity.test(elem.currentStyle.filter || "") ?
5996:                 (parseFloat(RegExp.$1) / 100) + "" :
5997:                 "";
5998:
5999:             return ret === "" ?
6000:                 "1" :
6001:                 ret;
6002:         }
6003:
6004:         // Make sure we're using the right name for getting the float value
6005:         if ( rfloat.test( name ) ) {
6006:             name = styleFloat;
6007:         }
6008:
6009:         if ( !force && style && style[ name ] ) {
6010:             ret = style[ name ];
6011:
6012:         } else if ( getComputedStyle ) {
6013:
6014:             // Only "float" is needed here
6015:             if ( rfloat.test( name ) ) {
6016:                 name = "float";
6017:             }
6018:
6019:             name = name.replace( rupper, "-$1" ).toLowerCase();
6020:
6021:             var defaultView = elem.ownerDocument.defaultView;
6022:
6023:             if ( !defaultView ) {
6024:                 return null;
6025:             }
6026:
6027:             var computedStyle = defaultView.getComputedStyle( elem, null );
6028:
6029:             if ( computedStyle ) {
6030:                 ret = computedStyle.getPropertyValue( name );
6031:             }
6032:
6033:             // We should always get a number back from opacity
6034:             if ( name === "opacity" && ret === "" ) {
6035:                 ret = "1";
6036:             }
6037:
6038:         } else if ( elem.currentStyle ) {
6039:             var camelCase = name.replace(rdashAlpha, fcamelCase);
6040:
6041:             ret = elem.currentStyle[ name ] || elem.currentStyle[ camelCase ];
6042:
6043:             // From the awesome hack by Dean Edwards
6044:             // http://erik.eae.net/archives/2007/07/27/18.54.15/#comment-102291
6045:
6046:             // If we're not dealing with a regular pixel number
6047:             // but a number that has a weird ending, we need to convert it to pixels
6048:             if ( !rnumpx.test( ret ) && rnum.test( ret ) ) {
6049:                 // Remember the original values
6050:                 var left = style.left, rsLeft = elem.runtimeStyle.left;
6051:
6052:                 // Put in the new values to get a computed value out
6053:                 elem.runtimeStyle.left = elem.currentStyle.left;
6054:                 style.left = camelCase === "fontSize" ? "1em" : (ret || 0);
6055:                 ret = style.pixelLeft + "px";
6056:
6057:                 // Revert the changed values
6058:                 style.left = left;
6059:                 elem.runtimeStyle.left = rsLeft;
6060:             }
6061:         }
6062:
6063:         return ret;
6064:     },
6065:
6066:     // A method for quickly swapping in/out CSS properties to get correct calculations
6067:     swap: function( elem, options, callback ) {
6068:         ///    <summary>
6069:         ///        Swap in/out style options.
6070:         ///    </summary>
6071:
6072:         var old = {};
6073:
6074:         // Remember the old values, and insert the new ones
6075:         for ( var name in options ) {
6076:             old[ name ] = elem.style[ name ];
6077:             elem.style[ name ] = options[ name ];
6078:         }
6079:
6080:         callback.call( elem );
6081:
6082:         // Revert the old values
6083:         for ( var name in options ) {
6084:             elem.style[ name ] = old[ name ];
6085:         }
6086:     }
6087: });
6088:
6089: if ( jQuery.expr && jQuery.expr.filters ) {
6090:     jQuery.expr.filters.hidden = function( elem ) {
6091:         var width = elem.offsetWidth, height = elem.offsetHeight,
6092:             skip = elem.nodeName.toLowerCase() === "tr";
6093:
6094:         return width === 0 && height === 0 && !skip ?
6095:             true :
6096:             width > 0 && height > 0 && !skip ?
6097:                 false :
6098:                 jQuery.curCSS(elem, "display") === "none";
6099:     };
6100:
6101:     jQuery.expr.filters.visible = function( elem ) {
6102:         return !jQuery.expr.filters.hidden( elem );
6103:     };
6104: }
6105: var jsc = now(),
6106:     rscript = /<script(.|\s)*?\/script>/gi,
6107:     rselectTextarea = /select|textarea/i,
6108:     rinput = /color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week/i,
6109:     jsre = /=\?(&|$)/,
6110:     rquery = /\?/,
6111:     rts = /(\?|&)_=.*?(&|$)/,
6112:     rurl = /^(\w+:)?\/\/([^\/?#]+)/,
6113:     r20 = /%20/g;
6114:
6115: jQuery.fn.extend({
6116:     // Keep a copy of the old load
6117:     _load: jQuery.fn.load,
6118:
6119:     load: function( url, params, callback ) {
6120:         ///    <summary>
6121:         ///        Loads HTML from a remote file and injects it into the DOM. By default performs a GET request, but if parameters are included
6122:         ///        then a POST will be performed.
6123:         ///    </summary>
6124:         ///    <param name="url" type="String">The URL of the HTML page to load.</param>
6125:         ///    <param name="data" optional="true" type="Map">Key/value pairs that will be sent to the server.</param>
6126:         ///    <param name="callback" optional="true" type="Function">The function called when the AJAX request is complete. It should map function(responseText, textStatus, XMLHttpRequest) such that this maps the injected DOM element.</param>
6127:         ///    <returns type="jQuery" />
6128:
6129:         if ( typeof url !== "string" ) {
6130:             return this._load( url );
6131:
6132:         // Don't do a request if no elements are being requested
6133:         } else if ( !this.length ) {
6134:             return this;
6135:         }
6136:
6137:         var off = url.indexOf(" ");
6138:         if ( off >= 0 ) {
6139:             var selector = url.slice(off, url.length);
6140:             url = url.slice(0, off);
6141:         }
6142:
6143:         // Default to a GET request
6144:         var type = "GET";
6145:
6146:         // If the second parameter was provided
6147:         if ( params ) {
6148:             // If it's a function
6149:             if ( jQuery.isFunction( params ) ) {
6150:                 // We assume that it's the callback
6151:                 callback = params;
6152:                 params = null;
6153:
6154:             // Otherwise, build a param string
6155:             } else if ( typeof params === "object" ) {
6156:                 params = jQuery.param( params, jQuery.ajaxSettings.traditional );
6157:                 type = "POST";
6158:             }
6159:         }
6160:
6161:         var self = this;
6162:
6163:         // Request the remote document
6164:         jQuery.ajax({
6165:             url: url,
6166:             type: type,
6167:             dataType: "html",
6168:             data: params,
6169:             complete: function( res, status ) {
6170:                 // If successful, inject the HTML into all the matched elements
6171:                 if ( status === "success" || status === "notmodified" ) {
6172:                     // See if a selector was specified
6173:                     self.html( selector ?
6174:                         // Create a dummy div to hold the results
6175:                         jQuery("<div />")
6176:                             // inject the contents of the document in, removing the scripts
6177:                             // to avoid any 'Permission Denied' errors in IE
6178:                             .append(res.responseText.replace(rscript, ""))
6179: