ÿþ( f u n c t i o n ( ) { v a r   _ j Q u e r y = w i n d o w . j Q u e r y , _ $ = w i n d o w . $ ; v a r   j Q u e r y = w i n d o w . j Q u e r y = w i n d o w . $ = f u n c t i o n ( s e l e c t o r , c o n t e x t ) { r e t u r n   n e w   j Q u e r y . f n . i n i t ( s e l e c t o r , c o n t e x t ) } ; v a r   q u i c k E x p r = / ^ [ ^ < ] * ( < ( . | \ s ) + > ) [ ^ > ] * $ | ^ # ( \ w + ) $ / , i s S i m p l e = / ^ . [ ^ : # \ [ \ . ] * $ / , u n d e f i n e d ; j Q u e r y . f n = j Q u e r y . p r o t o t y p e = { i n i t : f u n c t i o n ( s e l e c t o r , c o n t e x t ) { s e l e c t o r = s e l e c t o r | | d o c u m e n t ; i f ( s e l e c t o r . n o d e T y p e ) { t h i s [ 0 ] = s e l e c t o r ; t h i s . l e n g t h = 1 ; r e t u r n   t h i s } i f ( t y p e o f   s e l e c t o r = = " s t r i n g " ) { v a r   m a t c h = q u i c k E x p r . e x e c ( s e l e c t o r ) ; i f ( m a t c h & & ( m a t c h [ 1 ] | | ! c o n t e x t ) ) { i f ( m a t c h [ 1 ] ) { s e l e c t o r = j Q u e r y . c l e a n ( [ m a t c h [ 1 ] ] , c o n t e x t ) } e l s e { v a r   e l e m = d o c u m e n t . g e t E l e m e n t B y I d ( m a t c h [ 3 ] ) ; i f ( e l e m ) { i f ( e l e m . i d ! = m a t c h [ 3 ] ) { r e t u r n   j Q u e r y ( ) . f i n d ( s e l e c t o r ) } r e t u r n   j Q u e r y ( e l e m ) } s e l e c t o r = [ ] } } e l s e { r e t u r n   j Q u e r y ( c o n t e x t ) . f i n d ( s e l e c t o r ) } } e l s e { i f ( j Q u e r y . i s F u n c t i o n ( s e l e c t o r ) ) { r e t u r n   j Q u e r y ( d o c u m e n t ) [ j Q u e r y . f n . r e a d y ? " r e a d y " : " l o a d " ] ( s e l e c t o r ) } } r e t u r n   t h i s . s e t A r r a y ( j Q u e r y . m a k e A r r a y ( s e l e c t o r ) ) } , j q u e r y : " 1 . 2 . 6 " , s i z e : f u n c t i o n ( ) { r e t u r n   t h i s . l e n g t h } , l e n g t h : 0 , g e t : f u n c t i o n ( n u m ) { r e t u r n   n u m = = u n d e f i n e d ? j Q u e r y . m a k e A r r a y ( t h i s ) : t h i s [ n u m ] } , p u s h S t a c k : f u n c t i o n ( e l e m s ) { v a r   r e t = j Q u e r y ( e l e m s ) ; r e t . p r e v O b j e c t = t h i s ; r e t u r n   r e t } , s e t A r r a y : f u n c t i o n ( e l e m s ) { t h i s . l e n g t h = 0 ; A r r a y . p r o t o t y p e . p u s h . a p p l y ( t h i s , e l e m s ) ; r e t u r n   t h i s } , e a c h : f u n c t i o n ( c a l l b a c k , a r g s ) { r e t u r n   j Q u e r y . e a c h ( t h i s , c a l l b a c k , a r g s ) } , i n d e x : f u n c t i o n ( e l e m ) { v a r   r e t = - 1 ; r e t u r n   j Q u e r y . i n A r r a y ( e l e m & & e l e m . j q u e r y ? e l e m [ 0 ] : e l e m , t h i s ) } , a t t r : f u n c t i o n ( n a m e , v a l u e , t y p e ) { v a r   o p t i o n s = n a m e ; i f ( n a m e . c o n s t r u c t o r = = S t r i n g ) { i f ( v a l u e = = = u n d e f i n e d ) { r e t u r n   t h i s [ 0 ] & & j Q u e r y [ t y p e | | " a t t r " ] ( t h i s [ 0 ] , n a m e ) } e l s e { o p t i o n s = { } ; o p t i o n s [ n a m e ] = v a l u e } } r e t u r n   t h i s . e a c h ( f u n c t i o n ( i ) { f o r ( n a m e   i n   o p t i o n s ) { j Q u e r y . a t t r ( t y p e ? t h i s . s t y l e : t h i s , n a m e , j Q u e r y . p r o p ( t h i s , o p t i o n s [ n a m e ] , t y p e , i , n a m e ) ) } } ) } , c s s : f u n c t i o n ( k e y , v a l u e ) { i f ( ( k e y = = " w i d t h " | | k e y = = " h e i g h t " ) & & p a r s e F l o a t ( v a l u e ) < 0 ) { v a l u e = u n d e f i n e d } r e t u r n   t h i s . a t t r ( k e y , v a l u e , " c u r C S S " ) } , t e x t : f u n c t i o n ( t e x t ) { i f ( t y p e o f   t e x t ! = " o b j e c t " & & t e x t ! = n u l l ) { r e t u r n   t h i s . e m p t y ( ) . a p p e n d ( ( t h i s [ 0 ] & & t h i s [ 0 ] . o w n e r D o c u m e n t | | d o c u m e n t ) . c r e a t e T e x t N o d e ( t e x t ) ) } v a r   r e t = " " ; j Q u e r y . e a c h ( t e x t | | t h i s , f u n c t i o n ( ) { j Q u e r y . e a c h ( t h i s . c h i l d N o d e s , f u n c t i o n ( ) { i f ( t h i s . n o d e T y p e ! = 8 ) { r e t + = t h i s . n o d e T y p e ! = 1 ? t h i s . n o d e V a l u e : j Q u e r y . f n . t e x t ( [ t h i s ] ) } } ) } ) ; r e t u r n   r e t } , w r a p A l l : f u n c t i o n ( h t m l ) { i f ( t h i s [ 0 ] ) { j Q u e r y ( h t m l , t h i s [ 0 ] . o w n e r D o c u m e n t ) . c l o n e ( ) . i n s e r t B e f o r e ( t h i s [ 0 ] ) . m a p ( f u n c t i o n ( ) { v a r   e l e m = t h i s ; w h i l e ( e l e m . f i r s t C h i l d ) { e l e m = e l e m . f i r s t C h i l d } r e t u r n   e l e m } ) . a p p e n d ( t h i s ) } r e t u r n   t h i s } , w r a p I n n e r : f u n c t i o n ( h t m l ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { j Q u e r y ( t h i s ) . c o n t e n t s ( ) . w r a p A l l ( h t m l ) } ) } , w r a p : f u n c t i o n ( h t m l ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { j Q u e r y ( t h i s ) . w r a p A l l ( h t m l ) } ) } , a p p e n d : f u n c t i o n ( ) { r e t u r n   t h i s . d o m M a n i p ( a r g u m e n t s , t r u e , f a l s e , f u n c t i o n ( e l e m ) { i f ( t h i s . n o d e T y p e = = 1 ) { t h i s . a p p e n d C h i l d ( e l e m ) } } ) } , p r e p e n d : f u n c t i o n ( ) { r e t u r n   t h i s . d o m M a n i p ( a r g u m e n t s , t r u e , t r u e , f u n c t i o n ( e l e m ) { i f ( t h i s . n o d e T y p e = = 1 ) { t h i s . i n s e r t B e f o r e ( e l e m , t h i s . f i r s t C h i l d ) } } ) } , b e f o r e : f u n c t i o n ( ) { r e t u r n   t h i s . d o m M a n i p ( a r g u m e n t s , f a l s e , f a l s e , f u n c t i o n ( e l e m ) { t h i s . p a r e n t N o d e . i n s e r t B e f o r e ( e l e m , t h i s ) } ) } , a f t e r : f u n c t i o n ( ) { r e t u r n   t h i s . d o m M a n i p ( a r g u m e n t s , f a l s e , t r u e , f u n c t i o n ( e l e m ) { t h i s . p a r e n t N o d e . i n s e r t B e f o r e ( e l e m , t h i s . n e x t S i b l i n g ) } ) } , e n d : f u n c t i o n ( ) { r e t u r n   t h i s . p r e v O b j e c t | | j Q u e r y ( [ ] ) } , f i n d : f u n c t i o n ( s e l e c t o r ) { v a r   e l e m s = j Q u e r y . m a p ( t h i s , f u n c t i o n ( e l e m ) { r e t u r n   j Q u e r y . f i n d ( s e l e c t o r , e l e m ) } ) ; r e t u r n   t h i s . p u s h S t a c k ( / [ ^ + > ]   [ ^ + > ] / . t e s t ( s e l e c t o r ) | | s e l e c t o r . i n d e x O f ( " . . " ) > - 1 ? j Q u e r y . u n i q u e ( e l e m s ) : e l e m s ) } , c l o n e : f u n c t i o n ( e v e n t s ) { v a r   r e t = t h i s . m a p ( f u n c t i o n ( ) { i f ( j Q u e r y . b r o w s e r . m s i e & & ! j Q u e r y . i s X M L D o c ( t h i s ) ) { v a r   c l o n e = t h i s . c l o n e N o d e ( t r u e ) , c o n t a i n e r = d o c u m e n t . c r e a t e E l e m e n t ( " d i v " ) ; c o n t a i n e r . a p p e n d C h i l d ( c l o n e ) ; r e t u r n   j Q u e r y . c l e a n ( [ c o n t a i n e r . i n n e r H T M L ] ) [ 0 ] } e l s e { r e t u r n   t h i s . c l o n e N o d e ( t r u e ) } } ) ; v a r   c l o n e = r e t . f i n d ( " * " ) . a n d S e l f ( ) . e a c h ( f u n c t i o n ( ) { i f ( t h i s [ e x p a n d o ] ! = u n d e f i n e d ) { t h i s [ e x p a n d o ] = n u l l } } ) ; i f ( e v e n t s = = = t r u e ) { t h i s . f i n d ( " * " ) . a n d S e l f ( ) . e a c h ( f u n c t i o n ( i ) { i f ( t h i s . n o d e T y p e = = 3 ) { r e t u r n   } v a r   e v e n t s = j Q u e r y . d a t a ( t h i s , " e v e n t s " ) ; f o r ( v a r   t y p e   i n   e v e n t s ) { f o r ( v a r   h a n d l e r   i n   e v e n t s [ t y p e ] ) { j Q u e r y . e v e n t . a d d ( c l o n e [ i ] , t y p e , e v e n t s [ t y p e ] [ h a n d l e r ] , e v e n t s [ t y p e ] [ h a n d l e r ] . d a t a ) } } } ) } r e t u r n   r e t } , f i l t e r : f u n c t i o n ( s e l e c t o r ) { r e t u r n   t h i s . p u s h S t a c k ( j Q u e r y . i s F u n c t i o n ( s e l e c t o r ) & & j Q u e r y . g r e p ( t h i s , f u n c t i o n ( e l e m , i ) { r e t u r n   s e l e c t o r . c a l l ( e l e m , i ) } ) | | j Q u e r y . m u l t i F i l t e r ( s e l e c t o r , t h i s ) ) } , n o t : f u n c t i o n ( s e l e c t o r ) { i f ( s e l e c t o r . c o n s t r u c t o r = = S t r i n g ) { i f ( i s S i m p l e . t e s t ( s e l e c t o r ) ) { r e t u r n   t h i s . p u s h S t a c k ( j Q u e r y . m u l t i F i l t e r ( s e l e c t o r , t h i s , t r u e ) ) } e l s e { s e l e c t o r = j Q u e r y . m u l t i F i l t e r ( s e l e c t o r , t h i s ) } } v a r   i s A r r a y L i k e = s e l e c t o r . l e n g t h & & s e l e c t o r [ s e l e c t o r . l e n g t h - 1 ] ! = = u n d e f i n e d & & ! s e l e c t o r . n o d e T y p e ; r e t u r n   t h i s . f i l t e r ( f u n c t i o n ( ) { r e t u r n   i s A r r a y L i k e ? j Q u e r y . i n A r r a y ( t h i s , s e l e c t o r ) < 0 : t h i s ! = s e l e c t o r } ) } , a d d : f u n c t i o n ( s e l e c t o r ) { r e t u r n   t h i s . p u s h S t a c k ( j Q u e r y . u n i q u e ( j Q u e r y . m e r g e ( t h i s . g e t ( ) , t y p e o f   s e l e c t o r = = " s t r i n g " ? j Q u e r y ( s e l e c t o r ) : j Q u e r y . m a k e A r r a y ( s e l e c t o r ) ) ) ) } , i s : f u n c t i o n ( s e l e c t o r ) { r e t u r n   ! ! s e l e c t o r & & j Q u e r y . m u l t i F i l t e r ( s e l e c t o r , t h i s ) . l e n g t h > 0 } , h a s C l a s s : f u n c t i o n ( s e l e c t o r ) { r e t u r n   t h i s . i s ( " . " + s e l e c t o r ) } , v a l : f u n c t i o n ( v a l u e ) { i f ( v a l u e = = u n d e f i n e d ) { i f ( t h i s . l e n g t h ) { v a r   e l e m = t h i s [ 0 ] ; i f ( j Q u e r y . n o d e N a m e ( e l e m , " s e l e c t " ) ) { v a r   i n d e x = e l e m . s e l e c t e d I n d e x , v a l u e s = [ ] , o p t i o n s = e l e m . o p t i o n s , o n e = e l e m . t y p e = = " s e l e c t - o n e " ; i f ( i n d e x < 0 ) { r e t u r n   n u l l } f o r ( v a r   i = o n e ? i n d e x : 0 , m a x = o n e ? i n d e x + 1 : o p t i o n s . l e n g t h ; i < m a x ; i + + ) { v a r   o p t i o n = o p t i o n s [ i ] ; i f ( o p t i o n . s e l e c t e d ) { v a l u e = j Q u e r y . b r o w s e r . m s i e & & ! o p t i o n . a t t r i b u t e s . v a l u e . s p e c i f i e d ? o p t i o n . t e x t : o p t i o n . v a l u e ; i f ( o n e ) { r e t u r n   v a l u e } v a l u e s . p u s h ( v a l u e ) } } r e t u r n   v a l u e s } e l s e { r e t u r n ( t h i s [ 0 ] . v a l u e | | " " ) . r e p l a c e ( / \ r / g , " " ) } } r e t u r n   u n d e f i n e d } i f ( v a l u e . c o n s t r u c t o r = = N u m b e r ) { v a l u e + = " " } r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { i f ( t h i s . n o d e T y p e ! = 1 ) { r e t u r n   } i f ( v a l u e . c o n s t r u c t o r = = A r r a y & & / r a d i o | c h e c k b o x / . t e s t ( t h i s . t y p e ) ) { t h i s . c h e c k e d = ( j Q u e r y . i n A r r a y ( t h i s . v a l u e , v a l u e ) > = 0 | | j Q u e r y . i n A r r a y ( t h i s . n a m e , v a l u e ) > = 0 ) } e l s e { i f ( j Q u e r y . n o d e N a m e ( t h i s , " s e l e c t " ) ) { v a r   v a l u e s = j Q u e r y . m a k e A r r a y ( v a l u e ) ; j Q u e r y ( " o p t i o n " , t h i s ) . e a c h ( f u n c t i o n ( ) { t h i s . s e l e c t e d = ( j Q u e r y . i n A r r a y ( t h i s . v a l u e , v a l u e s ) > = 0 | | j Q u e r y . i n A r r a y ( t h i s . t e x t , v a l u e s ) > = 0 ) } ) ; i f ( ! v a l u e s . l e n g t h ) { t h i s . s e l e c t e d I n d e x = - 1 } } e l s e { t h i s . v a l u e = v a l u e } } } ) } , h t m l : f u n c t i o n ( v a l u e ) { r e t u r n   v a l u e = = u n d e f i n e d ? ( t h i s [ 0 ] ? t h i s [ 0 ] . i n n e r H T M L : n u l l ) : t h i s . e m p t y ( ) . a p p e n d ( v a l u e ) } , r e p l a c e W i t h : f u n c t i o n ( v a l u e ) { r e t u r n   t h i s . a f t e r ( v a l u e ) . r e m o v e ( ) } , e q : f u n c t i o n ( i ) { r e t u r n   t h i s . s l i c e ( i , i + 1 ) } , s l i c e : f u n c t i o n ( ) { r e t u r n   t h i s . p u s h S t a c k ( A r r a y . p r o t o t y p e . s l i c e . a p p l y ( t h i s , a r g u m e n t s ) ) } , m a p : f u n c t i o n ( c a l l b a c k ) { r e t u r n   t h i s . p u s h S t a c k ( j Q u e r y . m a p ( t h i s , f u n c t i o n ( e l e m , i ) { r e t u r n   c a l l b a c k . c a l l ( e l e m , i , e l e m ) } ) ) } , a n d S e l f : f u n c t i o n ( ) { r e t u r n   t h i s . a d d ( t h i s . p r e v O b j e c t ) } , d a t a : f u n c t i o n ( k e y , v a l u e ) { v a r   p a r t s = k e y . s p l i t ( " . " ) ; p a r t s [ 1 ] = p a r t s [ 1 ] ? " . " + p a r t s [ 1 ] : " " ; i f ( v a l u e = = = u n d e f i n e d ) { v a r   d a t a = t h i s . t r i g g e r H a n d l e r ( " g e t D a t a " + p a r t s [ 1 ] + " ! " , [ p a r t s [ 0 ] ] ) ; i f ( d a t a = = = u n d e f i n e d & & t h i s . l e n g t h ) { d a t a = j Q u e r y . d a t a ( t h i s [ 0 ] , k e y ) } r e t u r n   d a t a = = = u n d e f i n e d & & p a r t s [ 1 ] ? t h i s . d a t a ( p a r t s [ 0 ] ) : d a t a } e l s e { r e t u r n   t h i s . t r i g g e r ( " s e t D a t a " + p a r t s [ 1 ] + " ! " , [ p a r t s [ 0 ] , v a l u e ] ) . e a c h ( f u n c t i o n ( ) { j Q u e r y . d a t a ( t h i s , k e y , v a l u e ) } ) } } , r e m o v e D a t a : f u n c t i o n ( k e y ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { j Q u e r y . r e m o v e D a t a ( t h i s , k e y ) } ) } , d o m M a n i p : f u n c t i o n ( a r g s , t a b l e , r e v e r s e , c a l l b a c k ) { v a r   c l o n e = t h i s . l e n g t h > 1 , e l e m s ; r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { i f ( ! e l e m s ) { e l e m s = j Q u e r y . c l e a n ( a r g s , t h i s . o w n e r D o c u m e n t ) ; i f ( r e v e r s e ) { e l e m s . r e v e r s e ( ) } } v a r   o b j = t h i s ; i f ( t a b l e & & j Q u e r y . n o d e N a m e ( t h i s , " t a b l e " ) & & j Q u e r y . n o d e N a m e ( e l e m s [ 0 ] , " t r " ) ) { o b j = t h i s . g e t E l e m e n t s B y T a g N a m e ( " t b o d y " ) [ 0 ] | | t h i s . a p p e n d C h i l d ( t h i s . o w n e r D o c u m e n t . c r e a t e E l e m e n t ( " t b o d y " ) ) } v a r   s c r i p t s = j Q u e r y ( [ ] ) ; j Q u e r y . e a c h ( e l e m s , f u n c t i o n ( ) { v a r   e l e m = c l o n e ? j Q u e r y ( t h i s ) . c l o n e ( t r u e ) [ 0 ] : t h i s ; i f ( j Q u e r y . n o d e N a m e ( e l e m , " s c r i p t " ) ) { s c r i p t s = s c r i p t s . a d d ( e l e m ) } e l s e { i f ( e l e m . n o d e T y p e = = 1 ) { s c r i p t s = s c r i p t s . a d d ( j Q u e r y ( " s c r i p t " , e l e m ) . r e m o v e ( ) ) } c a l l b a c k . c a l l ( o b j , e l e m ) } } ) ; s c r i p t s . e a c h ( e v a l S c r i p t ) } ) } } ; j Q u e r y . f n . i n i t . p r o t o t y p e = j Q u e r y . f n ; f u n c t i o n   e v a l S c r i p t ( i , e l e m ) { i f ( e l e m . s r c ) { j Q u e r y . a j a x ( { u r l : e l e m . s r c , a s y n c : f a l s e , d a t a T y p e : " s c r i p t " } ) } e l s e { j Q u e r y . g l o b a l E v a l ( e l e m . t e x t | | e l e m . t e x t C o n t e n t | | e l e m . i n n e r H T M L | | " " ) } i f ( e l e m . p a r e n t N o d e ) { e l e m . p a r e n t N o d e . r e m o v e C h i l d ( e l e m ) } } f u n c t i o n   n o w ( ) { r e t u r n   + n e w   D a t e } j Q u e r y . e x t e n d = j Q u e r y . f n . e x t e n d = f u n c t i o n ( ) { v a r   t a r g e t = a r g u m e n t s [ 0 ] | | { } , i = 1 , l e n g t h = a r g u m e n t s . l e n g t h , d e e p = f a l s e , o p t i o n s ; i f ( t a r g e t . c o n s t r u c t o r = = B o o l e a n ) { d e e p = t a r g e t ; t a r g e t = a r g u m e n t s [ 1 ] | | { } ; i = 2 } i f ( t y p e o f   t a r g e t ! = " o b j e c t " & & t y p e o f   t a r g e t ! = " f u n c t i o n " ) { t a r g e t = { } } i f ( l e n g t h = = i ) { t a r g e t = t h i s ; - - i } f o r ( ; i < l e n g t h ; i + + ) { i f ( ( o p t i o n s = a r g u m e n t s [ i ] ) ! = n u l l ) { f o r ( v a r   n a m e   i n   o p t i o n s ) { v a r   s r c = t a r g e t [ n a m e ] , c o p y = o p t i o n s [ n a m e ] ; i f ( t a r g e t = = = c o p y ) { c o n t i n u e } i f ( d e e p & & c o p y & & t y p e o f   c o p y = = " o b j e c t " & & ! c o p y . n o d e T y p e ) { t a r g e t [ n a m e ] = j Q u e r y . e x t e n d ( d e e p , s r c | | ( c o p y . l e n g t h ! = n u l l ? [ ] : { } ) , c o p y ) } e l s e { i f ( c o p y ! = = u n d e f i n e d ) { t a r g e t [ n a m e ] = c o p y } } } } } r e t u r n   t a r g e t } ; v a r   e x p a n d o = " j Q u e r y " + n o w ( ) , u u i d = 0 , w i n d o w D a t a = { } , e x c l u d e = / z - ? i n d e x | f o n t - ? w e i g h t | o p a c i t y | z o o m | l i n e - ? h e i g h t / i , d e f a u l t V i e w = d o c u m e n t . d e f a u l t V i e w | | { } ; j Q u e r y . e x t e n d ( { n o C o n f l i c t : f u n c t i o n ( d e e p ) { w i n d o w . $ = _ $ ; i f ( d e e p ) { w i n d o w . j Q u e r y = _ j Q u e r y } r e t u r n   j Q u e r y } , i s F u n c t i o n : f u n c t i o n ( f n ) { r e t u r n   ! ! f n & & t y p e o f   f n ! = " s t r i n g " & & ! f n . n o d e N a m e & & f n . c o n s t r u c t o r ! = A r r a y & & / ^ [ \ s [ ] ? f u n c t i o n / . t e s t ( f n + " " ) } , i s X M L D o c : f u n c t i o n ( e l e m ) { r e t u r n   e l e m . d o c u m e n t E l e m e n t & & ! e l e m . b o d y | | e l e m . t a g N a m e & & e l e m . o w n e r D o c u m e n t & & ! e l e m . o w n e r D o c u m e n t . b o d y } , g l o b a l E v a l : f u n c t i o n ( d a t a ) { d a t a = j Q u e r y . t r i m ( d a t a ) ; i f ( d a t a ) { v a r   h e a d = d o c u m e n t . g e t E l e m e n t s B y T a g N a m e ( " h e a d " ) [ 0 ] | | d o c u m e n t . d o c u m e n t E l e m e n t , s c r i p t = d o c u m e n t . c r e a t e E l e m e n t ( " s c r i p t " ) ; s c r i p t . t y p e = " t e x t / j a v a s c r i p t " ; i f ( j Q u e r y . b r o w s e r . m s i e ) { s c r i p t . t e x t = d a t a } e l s e { s c r i p t . a p p e n d C h i l d ( d o c u m e n t . c r e a t e T e x t N o d e ( d a t a ) ) } h e a d . i n s e r t B e f o r e ( s c r i p t , h e a d . f i r s t C h i l d ) ; h e a d . r e m o v e C h i l d ( s c r i p t ) } } , n o d e N a m e : f u n c t i o n ( e l e m , n a m e ) { r e t u r n   e l e m . n o d e N a m e & & e l e m . n o d e N a m e . t o U p p e r C a s e ( ) = = n a m e . t o U p p e r C a s e ( ) } , c a c h e : { } , d a t a : f u n c t i o n ( e l e m , n a m e , d a t a ) { e l e m = e l e m = = w i n d o w ? w i n d o w D a t a : e l e m ; v a r   i d = e l e m [ e x p a n d o ] ; i f ( ! i d ) { i d = e l e m [ e x p a n d o ] = + + u u i d } i f ( n a m e & & ! j Q u e r y . c a c h e [ i d ] ) { j Q u e r y . c a c h e [ i d ] = { } } i f ( d a t a ! = = u n d e f i n e d ) { j Q u e r y . c a c h e [ i d ] [ n a m e ] = d a t a } r e t u r n   n a m e ? j Q u e r y . c a c h e [ i d ] [ n a m e ] : i d } , r e m o v e D a t a : f u n c t i o n ( e l e m , n a m e ) { e l e m = e l e m = = w i n d o w ? w i n d o w D a t a : e l e m ; v a r   i d = e l e m [ e x p a n d o ] ; i f ( n a m e ) { i f ( j Q u e r y . c a c h e [ i d ] ) { d e l e t e   j Q u e r y . c a c h e [ i d ] [ n a m e ] ; n a m e = " " ; f o r ( n a m e   i n   j Q u e r y . c a c h e [ i d ] ) { b r e a k } i f ( ! n a m e ) { j Q u e r y . r e m o v e D a t a ( e l e m ) } } } e l s e { t r y { d e l e t e   e l e m [ e x p a n d o ] } c a t c h ( e ) { i f ( e l e m . r e m o v e A t t r i b u t e ) { e l e m . r e m o v e A t t r i b u t e ( e x p a n d o ) } } d e l e t e   j Q u e r y . c a c h e [ i d ] } } , e a c h : f u n c t i o n ( o b j e c t , c a l l b a c k , a r g s ) { v a r   n a m e , i = 0 , l e n g t h = o b j e c t . l e n g t h ; i f ( a r g s ) { i f ( l e n g t h = = u n d e f i n e d ) { f o r ( n a m e   i n   o b j e c t ) { i f ( c a l l b a c k . a p p l y ( o b j e c t [ n a m e ] , a r g s ) = = = f a l s e ) { b r e a k } } } e l s e { f o r ( ; i < l e n g t h ; ) { i f ( c a l l b a c k . a p p l y ( o b j e c t [ i + + ] , a r g s ) = = = f a l s e ) { b r e a k } } } } e l s e { i f ( l e n g t h = = u n d e f i n e d ) { f o r ( n a m e   i n   o b j e c t ) { i f ( c a l l b a c k . c a l l ( o b j e c t [ n a m e ] , n a m e , o b j e c t [ n a m e ] ) = = = f a l s e ) { b r e a k } } } e l s e { f o r ( v a r   v a l u e = o b j e c t [ 0 ] ; i < l e n g t h & & c a l l b a c k . c a l l ( v a l u e , i , v a l u e ) ! = = f a l s e ; v a l u e = o b j e c t [ + + i ] ) { } } } r e t u r n   o b j e c t } , p r o p : f u n c t i o n ( e l e m , v a l u e , t y p e , i , n a m e ) { i f ( j Q u e r y . i s F u n c t i o n ( v a l u e ) ) { v a l u e = v a l u e . c a l l ( e l e m , i ) } r e t u r n   v a l u e & & v a l u e . c o n s t r u c t o r = = N u m b e r & & t y p e = = " c u r C S S " & & ! e x c l u d e . t e s t ( n a m e ) ? v a l u e + " p x " : v a l u e } , c l a s s N a m e : { a d d : f u n c t i o n ( e l e m , c l a s s N a m e s ) { j Q u e r y . e a c h ( ( c l a s s N a m e s | | " " ) . s p l i t ( / \ s + / ) , f u n c t i o n ( i , c l a s s N a m e ) { i f ( e l e m . n o d e T y p e = = 1 & & ! j Q u e r y . c l a s s N a m e . h a s ( e l e m . c l a s s N a m e , c l a s s N a m e ) ) { e l e m . c l a s s N a m e + = ( e l e m . c l a s s N a m e ? "   " : " " ) + c l a s s N a m e } } ) } , r e m o v e : f u n c t i o n ( e l e m , c l a s s N a m e s ) { i f ( e l e m . n o d e T y p e = = 1 ) { e l e m . c l a s s N a m e = c l a s s N a m e s ! = u n d e f i n e d ? j Q u e r y . g r e p ( e l e m . c l a s s N a m e . s p l i t ( / \ s + / ) , f u n c t i o n ( c l a s s N a m e ) { r e t u r n   ! j Q u e r y . c l a s s N a m e . h a s ( c l a s s N a m e s , c l a s s N a m e ) } ) . j o i n ( "   " ) : " " } } , h a s : f u n c t i o n ( e l e m , c l a s s N a m e ) { r e t u r n   j Q u e r y . i n A r r a y ( c l a s s N a m e , ( e l e m . c l a s s N a m e | | e l e m ) . t o S t r i n g ( ) . s p l i t ( / \ s + / ) ) > - 1 } } , s w a p : f u n c t i o n ( e l e m , o p t i o n s , c a l l b a c k ) { v a r   o l d = { } ; f o r ( v a r   n a m e   i n   o p t i o n s ) { o l d [ n a m e ] = e l e m . s t y l e [ n a m e ] ; e l e m . s t y l e [ n a m e ] = o p t i o n s [ n a m e ] } c a l l b a c k . c a l l ( e l e m ) ; f o r ( v a r   n a m e   i n   o p t i o n s ) { e l e m . s t y l e [ n a m e ] = o l d [ n a m e ] } } , c s s : f u n c t i o n ( e l e m , n a m e , f o r c e ) { i f ( n a m e = = " w i d t h " | | n a m e = = " h e i g h t " ) { v a r   v a l , p r o p s = { p o s i t i o n : " a b s o l u t e " , v i s i b i l i t y : " h i d d e n " , d i s p l a y : " b l o c k " } , w h i c h = n a m e = = " w i d t h " ? [ " L e f t " , " R i g h t " ] : [ " T o p " , " B o t t o m " ] ; f u n c t i o n   g e t W H ( ) { v a l = n a m e = = " w i d t h " ? e l e m . o f f s e t W i d t h : e l e m . o f f s e t H e i g h t ; v a r   p a d d i n g = 0 , b o r d e r = 0 ; j Q u e r y . e a c h ( w h i c h , f u n c t i o n ( ) { p a d d i n g + = p a r s e F l o a t ( j Q u e r y . c u r C S S ( e l e m , " p a d d i n g " + t h i s , t r u e ) ) | | 0 ; b o r d e r + = p a r s e F l o a t ( j Q u e r y . c u r C S S ( e l e m , " b o r d e r " + t h i s + " W i d t h " , t r u e ) ) | | 0 } ) ; v a l - = M a t h . r o u n d ( p a d d i n g + b o r d e r ) } i f ( j Q u e r y ( e l e m ) . i s ( " : v i s i b l e " ) ) { g e t W H ( ) } e l s e { j Q u e r y . s w a p ( e l e m , p r o p s , g e t W H ) } r e t u r n   M a t h . m a x ( 0 , v a l ) } r e t u r n   j Q u e r y . c u r C S S ( e l e m , n a m e , f o r c e ) } , c u r C S S : f u n c t i o n ( e l e m , n a m e , f o r c e ) { v a r   r e t , s t y l e = e l e m . s t y l e ; f u n c t i o n   c o l o r ( e l e m ) { i f ( ! j Q u e r y . b r o w s e r . s a f a r i ) { r e t u r n   f a l s e } v a r   r e t = d e f a u l t V i e w . g e t C o m p u t e d S t y l e ( e l e m , n u l l ) ; r e t u r n   ! r e t | | r e t . g e t P r o p e r t y V a l u e ( " c o l o r " ) = = " " } i f ( n a m e = = " o p a c i t y " & & j Q u e r y . b r o w s e r . m s i e ) { r e t = j Q u e r y . a t t r ( s t y l e , " o p a c i t y " ) ; r e t u r n   r e t = = " " ? " 1 " : r e t } i f ( j Q u e r y . b r o w s e r . o p e r a & & n a m e = = " d i s p l a y " ) { v a r   s a v e = s t y l e . o u t l i n e ; s t y l e . o u t l i n e = " 0   s o l i d   b l a c k " ; s t y l e . o u t l i n e = s a v e } i f ( n a m e . m a t c h ( / f l o a t / i ) ) { n a m e = s t y l e F l o a t } i f ( ! f o r c e & & s t y l e & & s t y l e [ n a m e ] ) { r e t = s t y l e [ n a m e ] } e l s e { i f ( d e f a u l t V i e w . g e t C o m p u t e d S t y l e ) { i f ( n a m e . m a t c h ( / f l o a t / i ) ) { n a m e = " f l o a t " } n a m e = n a m e . r e p l a c e ( / ( [ A - Z ] ) / g , " - $ 1 " ) . t o L o w e r C a s e ( ) ; v a r   c o m p u t e d S t y l e = d e f a u l t V i e w . g e t C o m p u t e d S t y l e ( e l e m , n u l l ) ; i f ( c o m p u t e d S t y l e & & ! c o l o r ( e l e m ) ) { r e t = c o m p u t e d S t y l e . g e t P r o p e r t y V a l u e ( n a m e ) } e l s e { v a r   s w a p = [ ] , s t a c k = [ ] , a = e l e m , i = 0 ; f o r ( ; a & & c o l o r ( a ) ; a = a . p a r e n t N o d e ) { s t a c k . u n s h i f t ( a ) } f o r ( ; i < s t a c k . l e n g t h ; i + + ) { i f ( c o l o r ( s t a c k [ i ] ) ) { s w a p [ i ] = s t a c k [ i ] . s t y l e . d i s p l a y ; s t a c k [ i ] . s t y l e . d i s p l a y = " b l o c k " } } r e t = n a m e = = " d i s p l a y " & & s w a p [ s t a c k . l e n g t h - 1 ] ! = n u l l ? " n o n e " : ( c o m p u t e d S t y l e & & c o m p u t e d S t y l e . g e t P r o p e r t y V a l u e ( n a m e ) ) | | " " ; f o r ( i = 0 ; i < s w a p . l e n g t h ; i + + ) { i f ( s w a p [ i ] ! = n u l l ) { s t a c k [ i ] . s t y l e . d i s p l a y = s w a p [ i ] } } } i f ( n a m e = = " o p a c i t y " & & r e t = = " " ) { r e t = " 1 " } } e l s e { i f ( e l e m . c u r r e n t S t y l e ) { v a r   c a m e l C a s e = n a m e . r e p l a c e ( / \ - ( \ w ) / g , f u n c t i o n ( a l l , l e t t e r ) { r e t u r n   l e t t e r . t o U p p e r C a s e ( ) } ) ; r e t = e l e m . c u r r e n t S t y l e [ n a m e ] | | e l e m . c u r r e n t S t y l e [ c a m e l C a s e ] ; i f ( ! / ^ \ d + ( p x ) ? $ / i . t e s t ( r e t ) & & / ^ \ d / . t e s t ( r e t ) ) { v a r   l e f t = s t y l e . l e f t , r s L e f t = e l e m . r u n t i m e S t y l e . l e f t ; e l e m . r u n t i m e S t y l e . l e f t = e l e m . c u r r e n t S t y l e . l e f t ; s t y l e . l e f t = r e t | | 0 ; r e t = s t y l e . p i x e l L e f t + " p x " ; s t y l e . l e f t = l e f t ; e l e m . r u n t i m e S t y l e . l e f t = r s L e f t } } } } r e t u r n   r e t } , c l e a n : f u n c t i o n ( e l e m s , c o n t e x t ) { v a r   r e t = [ ] ; c o n t e x t = c o n t e x t | | d o c u m e n t ; i f ( t y p e o f   c o n t e x t . c r e a t e E l e m e n t = = " u n d e f i n e d " ) { c o n t e x t = c o n t e x t . o w n e r D o c u m e n t | | c o n t e x t [ 0 ] & & c o n t e x t [ 0 ] . o w n e r D o c u m e n t | | d o c u m e n t } j Q u e r y . e a c h ( e l e m s , f u n c t i o n ( i , e l e m ) { i f ( ! e l e m ) { r e t u r n   } i f ( e l e m . c o n s t r u c t o r = = N u m b e r ) { e l e m + = " " } i f ( t y p e o f   e l e m = = " s t r i n g " ) { e l e m = e l e m . r e p l a c e ( / ( < ( \ w + ) [ ^ > ] * ? ) \ / > / g , f u n c t i o n ( a l l , f r o n t , t a g ) { r e t u r n   t a g . m a t c h ( / ^ ( a b b r | b r | c o l | i m g | i n p u t | l i n k | m e t a | p a r a m | h r | a r e a | e m b e d ) $ / i ) ? a l l : f r o n t + " > < / " + t a g + " > " } ) ; v a r   t a g s = j Q u e r y . t r i m ( e l e m ) . t o L o w e r C a s e ( ) , d i v = c o n t e x t . c r e a t e E l e m e n t ( " d i v " ) ; v a r   w r a p = ! t a g s . i n d e x O f ( " < o p t " ) & & [ 1 , " < s e l e c t   m u l t i p l e = ' m u l t i p l e ' > " , " < / s e l e c t > " ] | | ! t a g s . i n d e x O f ( " < l e g " ) & & [ 1 , " < f i e l d s e t > " , " < / f i e l d s e t > " ] | | t a g s . m a t c h ( / ^ < ( t h e a d | t b o d y | t f o o t | c o l g | c a p ) / ) & & [ 1 , " < t a b l e > " , " < / t a b l e > " ] | | ! t a g s . i n d e x O f ( " < t r " ) & & [ 2 , " < t a b l e > < t b o d y > " , " < / t b o d y > < / t a b l e > " ] | | ( ! t a g s . i n d e x O f ( " < t d " ) | | ! t a g s . i n d e x O f ( " < t h " ) ) & & [ 3 , " < t a b l e > < t b o d y > < t r > " , " < / t r > < / t b o d y > < / t a b l e > " ] | | ! t a g s . i n d e x O f ( " < c o l " ) & & [ 2 , " < t a b l e > < t b o d y > < / t b o d y > < c o l g r o u p > " , " < / c o l g r o u p > < / t a b l e > " ] | | j Q u e r y . b r o w s e r . m s i e & & [ 1 , " d i v < d i v > " , " < / d i v > " ] | | [ 0 , " " , " " ] ; d i v . i n n e r H T M L = w r a p [ 1 ] + e l e m + w r a p [ 2 ] ; w h i l e ( w r a p [ 0 ] - - ) { d i v = d i v . l a s t C h i l d } i f ( j Q u e r y . b r o w s e r . m s i e ) { v a r   t b o d y = ! t a g s . i n d e x O f ( " < t a b l e " ) & & t a g s . i n d e x O f ( " < t b o d y " ) < 0 ? d i v . f i r s t C h i l d & & d i v . f i r s t C h i l d . c h i l d N o d e s : w r a p [ 1 ] = = " < t a b l e > " & & t a g s . i n d e x O f ( " < t b o d y " ) < 0 ? d i v . c h i l d N o d e s : [ ] ; f o r ( v a r   j = t b o d y . l e n g t h - 1 ; j > = 0 ; - - j ) { i f ( j Q u e r y . n o d e N a m e ( t b o d y [ j ] , " t b o d y " ) & & ! t b o d y [ j ] . c h i l d N o d e s . l e n g t h ) { t b o d y [ j ] . p a r e n t N o d e . r e m o v e C h i l d ( t b o d y [ j ] ) } } i f ( / ^ \ s / . t e s t ( e l e m ) ) { d i v . i n s e r t B e f o r e ( c o n t e x t . c r e a t e T e x t N o d e ( e l e m . m a t c h ( / ^ \ s * / ) [ 0 ] ) , d i v . f i r s t C h i l d ) } } e l e m = j Q u e r y . m a k e A r r a y ( d i v . c h i l d N o d e s ) } i f ( e l e m . l e n g t h = = = 0 & & ( ! j Q u e r y . n o d e N a m e ( e l e m , " f o r m " ) & & ! j Q u e r y . n o d e N a m e ( e l e m , " s e l e c t " ) ) ) { r e t u r n   } i f ( e l e m [ 0 ] = = u n d e f i n e d | | j Q u e r y . n o d e N a m e ( e l e m , " f o r m " ) | | e l e m . o p t i o n s ) { r e t . p u s h ( e l e m ) } e l s e { r e t = j Q u e r y . m e r g e ( r e t , e l e m ) } } ) ; r e t u r n   r e t } , a t t r : f u n c t i o n ( e l e m , n a m e , v a l u e ) { i f ( ! e l e m | | e l e m . n o d e T y p e = = 3 | | e l e m . n o d e T y p e = = 8 ) { r e t u r n   u n d e f i n e d } v a r   n o t x m l = ! j Q u e r y . i s X M L D o c ( e l e m ) , s e t = v a l u e ! = = u n d e f i n e d , m s i e = j Q u e r y . b r o w s e r . m s i e ; n a m e = n o t x m l & & j Q u e r y . p r o p s [ n a m e ] | | n a m e ; i f ( e l e m . t a g N a m e ) { v a r   s p e c i a l = / h r e f | s r c | s t y l e / . t e s t ( n a m e ) ; i f ( n a m e = = " s e l e c t e d " & & j Q u e r y . b r o w s e r . s a f a r i ) { e l e m . p a r e n t N o d e . s e l e c t e d I n d e x } i f ( n a m e   i n   e l e m & & n o t x m l & & ! s p e c i a l ) { i f ( s e t ) { i f ( n a m e = = " t y p e " & & j Q u e r y . n o d e N a m e ( e l e m , " i n p u t " ) & & e l e m . p a r e n t N o d e ) { t h r o w " t y p e   p r o p e r t y   c a n ' t   b e   c h a n g e d " } e l e m [ n a m e ] = v a l u e } i f ( j Q u e r y . n o d e N a m e ( e l e m , " f o r m " ) & & e l e m . g e t A t t r i b u t e N o d e ( n a m e ) ) { r e t u r n   e l e m . g e t A t t r i b u t e N o d e ( n a m e ) . n o d e V a l u e } r e t u r n   e l e m [ n a m e ] } i f ( m s i e & & n o t x m l & & n a m e = = " s t y l e " ) { r e t u r n   j Q u e r y . a t t r ( e l e m . s t y l e , " c s s T e x t " , v a l u e ) } i f ( s e t ) { e l e m . s e t A t t r i b u t e ( n a m e , " " + v a l u e ) } v a r   a t t r = m s i e & & n o t x m l & & s p e c i a l ? e l e m . g e t A t t r i b u t e ( n a m e , 2 ) : e l e m . g e t A t t r i b u t e ( n a m e ) ; r e t u r n   a t t r = = = n u l l ? u n d e f i n e d : a t t r } i f ( m s i e & & n a m e = = " o p a c i t y " ) { i f ( s e t ) { e l e m . z o o m = 1 ; e l e m . f i l t e r = ( e l e m . f i l t e r | | " " ) . r e p l a c e ( / a l p h a \ ( [ ^ ) ] * \ ) / , " " ) + ( p a r s e I n t ( v a l u e ) + " " = = " N a N " ? " " : " a l p h a ( o p a c i t y = " + v a l u e * 1 0 0 + " ) " ) } r e t u r n   e l e m . f i l t e r & & e l e m . f i l t e r . i n d e x O f ( " o p a c i t y = " ) > = 0 ? ( p a r s e F l o a t ( e l e m . f i l t e r . m a t c h ( / o p a c i t y = ( [ ^ ) ] * ) / ) [ 1 ] ) / 1 0 0 ) + " " : " " } n a m e = n a m e . r e p l a c e ( / - ( [ a - z ] ) / i g , f u n c t i o n ( a l l , l e t t e r ) { r e t u r n   l e t t e r . t o U p p e r C a s e ( ) } ) ; i f ( s e t ) { e l e m [ n a m e ] = v a l u e } r e t u r n   e l e m [ n a m e ] } , t r i m : f u n c t i o n ( t e x t ) { r e t u r n ( t e x t | | " " ) . r e p l a c e ( / ^ \ s + | \ s + $ / g , " " ) } , m a k e A r r a y : f u n c t i o n ( a r r a y ) { v a r   r e t = [ ] ; i f ( a r r a y ! = n u l l ) { v a r   i = a r r a y . l e n g t h ; i f ( i = = n u l l | | a r r a y . s p l i t | | a r r a y . s e t I n t e r v a l | | a r r a y . c a l l ) { r e t [ 0 ] = a r r a y } e l s e { w h i l e ( i ) { r e t [ - - i ] = a r r a y [ i ] } } } r e t u r n   r e t } , i n A r r a y : f u n c t i o n ( e l e m , a r r a y ) { f o r ( v a r   i = 0 , l e n g t h = a r r a y . l e n g t h ; i < l e n g t h ; i + + ) { i f ( a r r a y [ i ] = = = e l e m ) { r e t u r n   i } } r e t u r n   - 1 } , m e r g e : f u n c t i o n ( f i r s t , s e c o n d ) { v a r   i = 0 , e l e m , p o s = f i r s t . l e n g t h ; i f ( j Q u e r y . b r o w s e r . m s i e ) { w h i l e ( e l e m = s e c o n d [ i + + ] ) { i f ( e l e m . n o d e T y p e ! = 8 ) { f i r s t [ p o s + + ] = e l e m } } } e l s e { w h i l e ( e l e m = s e c o n d [ i + + ] ) { f i r s t [ p o s + + ] = e l e m } } r e t u r n   f i r s t } , u n i q u e : f u n c t i o n ( a r r a y ) { v a r   r e t = [ ] , d o n e = { } ; t r y { f o r ( v a r   i = 0 , l e n g t h = a r r a y . l e n g t h ; i < l e n g t h ; i + + ) { v a r   i d = j Q u e r y . d a t a ( a r r a y [ i ] ) ; i f ( ! d o n e [ i d ] ) { d o n e [ i d ] = t r u e ; r e t . p u s h ( a r r a y [ i ] ) } } } c a t c h ( e ) { r e t = a r r a y } r e t u r n   r e t } , g r e p : f u n c t i o n ( e l e m s , c a l l b a c k , i n v ) { v a r   r e t = [ ] ; f o r ( v a r   i = 0 , l e n g t h = e l e m s . l e n g t h ; i < l e n g t h ; i + + ) { i f ( ! i n v ! = ! c a l l b a c k ( e l e m s [ i ] , i ) ) { r e t . p u s h ( e l e m s [ i ] ) } } r e t u r n   r e t } , m a p : f u n c t i o n ( e l e m s , c a l l b a c k ) { v a r   r e t = [ ] ; f o r ( v a r   i = 0 , l e n g t h = e l e m s . l e n g t h ; i < l e n g t h ; i + + ) { v a r   v a l u e = c a l l b a c k ( e l e m s [ i ] , i ) ; i f ( v a l u e ! = n u l l ) { r e t [ r e t . l e n g t h ] = v a l u e } } r e t u r n   r e t . c o n c a t . a p p l y ( [ ] , r e t ) } } ) ; v a r   u s e r A g e n t = n a v i g a t o r . u s e r A g e n t . t o L o w e r C a s e ( ) ; j Q u e r y . b r o w s e r = { v e r s i o n : ( u s e r A g e n t . m a t c h ( / . + ( ? : r v | i t | r a | i e ) [ \ / :   ] ( [ \ d . ] + ) / ) | | [ ] ) [ 1 ] , s a f a r i : / w e b k i t / . t e s t ( u s e r A g e n t ) , o p e r a : / o p e r a / . t e s t ( u s e r A g e n t ) , m s i e : / m s i e / . t e s t ( u s e r A g e n t ) & & ! / o p e r a / . t e s t ( u s e r A g e n t ) , m o z i l l a : / m o z i l l a / . t e s t ( u s e r A g e n t ) & & ! / ( c o m p a t i b l e | w e b k i t ) / . t e s t ( u s e r A g e n t ) } ; v a r   s t y l e F l o a t = j Q u e r y . b r o w s e r . m s i e ? " s t y l e F l o a t " : " c s s F l o a t " ; j Q u e r y . e x t e n d ( { b o x M o d e l : ! j Q u e r y . b r o w s e r . m s i e | | d o c u m e n t . c o m p a t M o d e = = " C S S 1 C o m p a t " , p r o p s : { " f o r " : " h t m l F o r " , " c l a s s " : " c l a s s N a m e " , " f l o a t " : s t y l e F l o a t , c s s F l o a t : s t y l e F l o a t , s t y l e F l o a t : s t y l e F l o a t , r e a d o n l y : " r e a d O n l y " , m a x l e n g t h : " m a x L e n g t h " , c e l l s p a c i n g : " c e l l S p a c i n g " } } ) ; j Q u e r y . e a c h ( { p a r e n t : f u n c t i o n ( e l e m ) { r e t u r n   e l e m . p a r e n t N o d e } , p a r e n t s : f u n c t i o n ( e l e m ) { r e t u r n   j Q u e r y . d i r ( e l e m , " p a r e n t N o d e " ) } , n e x t : f u n c t i o n ( e l e m ) { r e t u r n   j Q u e r y . n t h ( e l e m , 2 , " n e x t S i b l i n g " ) } , p r e v : f u n c t i o n ( e l e m ) { r e t u r n   j Q u e r y . n t h ( e l e m , 2 , " p r e v i o u s S i b l i n g " ) } , n e x t A l l : f u n c t i o n ( e l e m ) { r e t u r n   j Q u e r y . d i r ( e l e m , " n e x t S i b l i n g " ) } , p r e v A l l : f u n c t i o n ( e l e m ) { r e t u r n   j Q u e r y . d i r ( e l e m , " p r e v i o u s S i b l i n g " ) } , s i b l i n g s : f u n c t i o n ( e l e m ) { r e t u r n   j Q u e r y . s i b l i n g ( e l e m . p a r e n t N o d e . f i r s t C h i l d , e l e m ) } , c h i l d r e n : f u n c t i o n ( e l e m ) { r e t u r n   j Q u e r y . s i b l i n g ( e l e m . f i r s t C h i l d ) } , c o n t e n t s : f u n c t i o n ( e l e m ) { r e t u r n   j Q u e r y . n o d e N a m e ( e l e m , " i f r a m e " ) ? e l e m . c o n t e n t D o c u m e n t | | e l e m . c o n t e n t W i n d o w . d o c u m e n t : j Q u e r y . m a k e A r r a y ( e l e m . c h i l d N o d e s ) } } , f u n c t i o n ( n a m e , f n ) { j Q u e r y . f n [ n a m e ] = f u n c t i o n ( s e l e c t o r ) { v a r   r e t = j Q u e r y . m a p ( t h i s , f n ) ; i f ( s e l e c t o r & & t y p e o f   s e l e c t o r = = " s t r i n g " ) { r e t = j Q u e r y . m u l t i F i l t e r ( s e l e c t o r , r e t ) } r e t u r n   t h i s . p u s h S t a c k ( j Q u e r y . u n i q u e ( r e t ) ) } } ) ; j Q u e r y . e a c h ( { a p p e n d T o : " a p p e n d " , p r e p e n d T o : " p r e p e n d " , i n s e r t B e f o r e : " b e f o r e " , i n s e r t A f t e r : " a f t e r " , r e p l a c e A l l : " r e p l a c e W i t h " } , f u n c t i o n ( n a m e , o r i g i n a l ) { j Q u e r y . f n [ n a m e ] = f u n c t i o n ( ) { v a r   a r g s = a r g u m e n t s ; r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { f o r ( v a r   i = 0 , l e n g t h = a r g s . l e n g t h ; i < l e n g t h ; i + + ) { j Q u e r y ( a r g s [ i ] ) [ o r i g i n a l ] ( t h i s ) } } ) } } ) ; j Q u e r y . e a c h ( { r e m o v e A t t r : f u n c t i o n ( n a m e ) { j Q u e r y . a t t r ( t h i s , n a m e , " " ) ; i f ( t h i s . n o d e T y p e = = 1 ) { t h i s . r e m o v e A t t r i b u t e ( n a m e ) } } , a d d C l a s s : f u n c t i o n ( c l a s s N a m e s ) { j Q u e r y . c l a s s N a m e . a d d ( t h i s , c l a s s N a m e s ) } , r e m o v e C l a s s : f u n c t i o n ( c l a s s N a m e s ) { j Q u e r y . c l a s s N a m e . r e m o v e ( t h i s , c l a s s N a m e s ) } , t o g g l e C l a s s : f u n c t i o n ( c l a s s N a m e s ) { j Q u e r y . c l a s s N a m e [ j Q u e r y . c l a s s N a m e . h a s ( t h i s , c l a s s N a m e s ) ? " r e m o v e " : " a d d " ] ( t h i s , c l a s s N a m e s ) } , r e m o v e : f u n c t i o n ( s e l e c t o r ) { i f ( ! s e l e c t o r | | j Q u e r y . f i l t e r ( s e l e c t o r , [ t h i s ] ) . r . l e n g t h ) { j Q u e r y ( " * " , t h i s ) . a d d ( t h i s ) . e a c h ( f u n c t i o n ( ) { j Q u e r y . e v e n t . r e m o v e ( t h i s ) ; j Q u e r y . r e m o v e D a t a ( t h i s ) } ) ; i f ( t h i s . p a r e n t N o d e ) { t h i s . p a r e n t N o d e . r e m o v e C h i l d ( t h i s ) } } } , e m p t y : f u n c t i o n ( ) { j Q u e r y ( " > * " , t h i s ) . r e m o v e ( ) ; w h i l e ( t h i s . f i r s t C h i l d ) { t h i s . r e m o v e C h i l d ( t h i s . f i r s t C h i l d ) } } } , f u n c t i o n ( n a m e , f n ) { j Q u e r y . f n [ n a m e ] = f u n c t i o n ( ) { r e t u r n   t h i s . e a c h ( f n , a r g u m e n t s ) } } ) ; j Q u e r y . e a c h ( [ " H e i g h t " , " W i d t h " ] , f u n c t i o n ( i , n a m e ) { v a r   t y p e = n a m e . t o L o w e r C a s e ( ) ; j Q u e r y . f n [ t y p e ] = f u n c t i o n ( s i z e ) { r e t u r n   t h i s [ 0 ] = = w i n d o w ? j Q u e r y . b r o w s e r . o p e r a & & d o c u m e n t . b o d y [ " c l i e n t " + n a m e ] | | j Q u e r y . b r o w s e r . s a f a r i & & w i n d o w [ " i n n e r " + n a m e ] | | d o c u m e n t . c o m p a t M o d e = = " C S S 1 C o m p a t " & & d o c u m e n t . d o c u m e n t E l e m e n t [ " c l i e n t " + n a m e ] | | d o c u m e n t . b o d y [ " c l i e n t " + n a m e ] : t h i s [ 0 ] = = d o c u m e n t ? M a t h . m a x ( M a t h . m a x ( d o c u m e n t . b o d y [ " s c r o l l " + n a m e ] , d o c u m e n t . d o c u m e n t E l e m e n t [ " s c r o l l " + n a m e ] ) , M a t h . m a x ( d o c u m e n t . b o d y [ " o f f s e t " + n a m e ] , d o c u m e n t . d o c u m e n t E l e m e n t [ " o f f s e t " + n a m e ] ) ) : s i z e = = u n d e f i n e d ? ( t h i s . l e n g t h ? j Q u e r y . c s s ( t h i s [ 0 ] , t y p e ) : n u l l ) : t h i s . c s s ( t y p e , s i z e . c o n s t r u c t o r = = S t r i n g ? s i z e : s i z e + " p x " ) } } ) ; f u n c t i o n   n u m ( e l e m , p r o p ) { r e t u r n   e l e m [ 0 ] & & p a r s e I n t ( j Q u e r y . c u r C S S ( e l e m [ 0 ] , p r o p , t r u e ) , 1 0 ) | | 0 } v a r   c h a r s = j Q u e r y . b r o w s e r . s a f a r i & & p a r s e I n t ( j Q u e r y . b r o w s e r . v e r s i o n ) < 4 1 7 ? " ( ? : [ \ \ w * _ - ] | \ \ \ \ . ) " : " ( ? : [ \ \ w \ u 0 1 2 8 - \ u F F F F * _ - ] | \ \ \ \ . ) " , q u i c k C h i l d = n e w   R e g E x p ( " ^ > \ \ s * ( " + c h a r s + " + ) " ) , q u i c k I D = n e w   R e g E x p ( " ^ ( " + c h a r s + " + ) ( # ) ( " + c h a r s + " + ) " ) , q u i c k C l a s s = n e w   R e g E x p ( " ^ ( [ # . ] ? ) ( " + c h a r s + " * ) " ) ; j Q u e r y . e x t e n d ( { e x p r : { " " : f u n c t i o n ( a , i , m ) { r e t u r n   m [ 2 ] = = " * " | | j Q u e r y . n o d e N a m e ( a , m [ 2 ] ) } , " # " : f u n c t i o n ( a , i , m ) { r e t u r n   a . g e t A t t r i b u t e ( " i d " ) = = m [ 2 ] } , " : " : { l t : f u n c t i o n ( a , i , m ) { r e t u r n   i < m [ 3 ] - 0 } , g t : f u n c t i o n ( a , i , m ) { r e t u r n   i > m [ 3 ] - 0 } , n t h : f u n c t i o n ( a , i , m ) { r e t u r n   m [ 3 ] - 0 = = i } , e q : f u n c t i o n ( a , i , m ) { r e t u r n   m [ 3 ] - 0 = = i } , f i r s t : f u n c t i o n ( a , i ) { r e t u r n   i = = 0 } , l a s t : f u n c t i o n ( a , i , m , r ) { r e t u r n   i = = r . l e n g t h - 1 } , e v e n : f u n c t i o n ( a , i ) { r e t u r n   i % 2 = = 0 } , o d d : f u n c t i o n ( a , i ) { r e t u r n   i % 2 } , " f i r s t - c h i l d " : f u n c t i o n ( a ) { r e t u r n   a . p a r e n t N o d e . g e t E l e m e n t s B y T a g N a m e ( " * " ) [ 0 ] = = a } , " l a s t - c h i l d " : f u n c t i o n ( a ) { r e t u r n   j Q u e r y . n t h ( a . p a r e n t N o d e . l a s t C h i l d , 1 , " p r e v i o u s S i b l i n g " ) = = a } , " o n l y - c h i l d " : f u n c t i o n ( a ) { r e t u r n   ! j Q u e r y . n t h ( a . p a r e n t N o d e . l a s t C h i l d , 2 , " p r e v i o u s S i b l i n g " ) } , p a r e n t : f u n c t i o n ( a ) { r e t u r n   a . f i r s t C h i l d } , e m p t y : f u n c t i o n ( a ) { r e t u r n   ! a . f i r s t C h i l d } , c o n t a i n s : f u n c t i o n ( a , i , m ) { r e t u r n ( a . t e x t C o n t e n t | | a . i n n e r T e x t | | j Q u e r y ( a ) . t e x t ( ) | | " " ) . i n d e x O f ( m [ 3 ] ) > = 0 } , v i s i b l e : f u n c t i o n ( a ) { r e t u r n " h i d d e n " ! = a . t y p e & & j Q u e r y . c s s ( a , " d i s p l a y " ) ! = " n o n e " & & j Q u e r y . c s s ( a , " v i s i b i l i t y " ) ! = " h i d d e n " } , h i d d e n : f u n c t i o n ( a ) { r e t u r n " h i d d e n " = = a . t y p e | | j Q u e r y . c s s ( a , " d i s p l a y " ) = = " n o n e " | | j Q u e r y . c s s ( a , " v i s i b i l i t y " ) = = " h i d d e n " } , e n a b l e d : f u n c t i o n ( a ) { r e t u r n   ! a . d i s a b l e d } , d i s a b l e d : f u n c t i o n ( a ) { r e t u r n   a . d i s a b l e d } , c h e c k e d : f u n c t i o n ( a ) { r e t u r n   a . c h e c k e d } , s e l e c t e d : f u n c t i o n ( a ) { r e t u r n   a . s e l e c t e d | | j Q u e r y . a t t r ( a , " s e l e c t e d " ) } , t e x t : f u n c t i o n ( a ) { r e t u r n " t e x t " = = a . t y p e } , r a d i o : f u n c t i o n ( a ) { r e t u r n " r a d i o " = = a . t y p e } , c h e c k b o x : f u n c t i o n ( a ) { r e t u r n " c h e c k b o x " = = a . t y p e } , f i l e : f u n c t i o n ( a ) { r e t u r n " f i l e " = = a . t y p e } , p a s s w o r d : f u n c t i o n ( a ) { r e t u r n " p a s s w o r d " = = a . t y p e } , s u b m i t : f u n c t i o n ( a ) { r e t u r n " s u b m i t " = = a . t y p e } , i m a g e : f u n c t i o n ( a ) { r e t u r n " i m a g e " = = a . t y p e } , r e s e t : f u n c t i o n ( a ) { r e t u r n " r e s e t " = = a . t y p e } , b u t t o n : f u n c t i o n ( a ) { r e t u r n " b u t t o n " = = a . t y p e | | j Q u e r y . n o d e N a m e ( a , " b u t t o n " ) } , i n p u t : f u n c t i o n ( a ) { r e t u r n / i n p u t | s e l e c t | t e x t a r e a | b u t t o n / i . t e s t ( a . n o d e N a m e ) } , h a s : f u n c t i o n ( a , i , m ) { r e t u r n   j Q u e r y . f i n d ( m [ 3 ] , a ) . l e n g t h } , h e a d e r : f u n c t i o n ( a ) { r e t u r n / h \ d / i . t e s t ( a . n o d e N a m e ) } , a n i m a t e d : f u n c t i o n ( a ) { r e t u r n   j Q u e r y . g r e p ( j Q u e r y . t i m e r s , f u n c t i o n ( f n ) { r e t u r n   a = = f n . e l e m } ) . l e n g t h } } } , p a r s e : [ / ^ ( \ [ )   * @ ? ( [ \ w - ] + )   * ( [ ! * $ ^ ~ = ] * )   * ( ' ? " ? ) ( . * ? ) \ 4   * \ ] / , / ^ ( : ) ( [ \ w - ] + ) \ ( " ? ' ? ( . * ? ( \ ( . * ? \ ) ) ? [ ^ ( ] * ? ) " ? ' ? \ ) / , n e w   R e g E x p ( " ^ ( [ : . # ] * ) ( " + c h a r s + " + ) " ) ] , m u l t i F i l t e r : f u n c t i o n ( e x p r , e l e m s , n o t ) { v a r   o l d , c u r = [ ] ; w h i l e ( e x p r & & e x p r ! = o l d ) { o l d = e x p r ; v a r   f = j Q u e r y . f i l t e r ( e x p r , e l e m s , n o t ) ; e x p r = f . t . r e p l a c e ( / ^ \ s * , \ s * / , " " ) ; c u r = n o t ? e l e m s = f . r : j Q u e r y . m e r g e ( c u r , f . r ) } r e t u r n   c u r } , f i n d : f u n c t i o n ( t , c o n t e x t ) { i f ( t y p e o f   t ! = " s t r i n g " ) { r e t u r n [ t ] } i f ( c o n t e x t & & c o n t e x t . n o d e T y p e ! = 1 & & c o n t e x t . n o d e T y p e ! = 9 ) { r e t u r n [ ] } c o n t e x t = c o n t e x t | | d o c u m e n t ; v a r   r e t = [ c o n t e x t ] , d o n e = [ ] , l a s t , n o d e N a m e ; w h i l e ( t & & l a s t ! = t ) { v a r   r = [ ] ; l a s t = t ; t = j Q u e r y . t r i m ( t ) ; v a r   f o u n d T o k e n = f a l s e , r e = q u i c k C h i l d , m = r e . e x e c ( t ) ; i f ( m ) { n o d e N a m e = m [ 1 ] . t o U p p e r C a s e ( ) ; f o r ( v a r   i = 0 ; r e t [ i ] ; i + + ) { f o r ( v a r   c = r e t [ i ] . f i r s t C h i l d ; c ; c = c . n e x t S i b l i n g ) { i f ( c . n o d e T y p e = = 1 & & ( n o d e N a m e = = " * " | | c . n o d e N a m e . t o U p p e r C a s e ( ) = = n o d e N a m e ) ) { r . p u s h ( c ) } } } r e t = r ; t = t . r e p l a c e ( r e , " " ) ; i f ( t . i n d e x O f ( "   " ) = = 0 ) { c o n t i n u e } f o u n d T o k e n = t r u e } e l s e { r e = / ^ ( [ > + ~ ] ) \ s * ( \ w * ) / i ; i f ( ( m = r e . e x e c ( t ) ) ! = n u l l ) { r = [ ] ; v a r   m e r g e = { } ; n o d e N a m e = m [ 2 ] . t o U p p e r C a s e ( ) ; m = m [ 1 ] ; f o r ( v a r   j = 0 , r l = r e t . l e n g t h ; j < r l ; j + + ) { v a r   n = m = = " ~ " | | m = = " + " ? r e t [ j ] . n e x t S i b l i n g : r e t [ j ] . f i r s t C h i l d ; f o r ( ; n ; n = n . n e x t S i b l i n g ) { i f ( n . n o d e T y p e = = 1 ) { v a r   i d = j Q u e r y . d a t a ( n ) ; i f ( m = = " ~ " & & m e r g e [ i d ] ) { b r e a k } i f ( ! n o d e N a m e | | n . n o d e N a m e . t o U p p e r C a s e ( ) = = n o d e N a m e ) { i f ( m = = " ~ " ) { m e r g e [ i d ] = t r u e } r . p u s h ( n ) } i f ( m = = " + " ) { b r e a k } } } } r e t = r ; t = j Q u e r y . t r i m ( t . r e p l a c e ( r e , " " ) ) ; f o u n d T o k e n = t r u e } } i f ( t & & ! f o u n d T o k e n ) { i f ( ! t . i n d e x O f ( " , " ) ) { i f ( c o n t e x t = = r e t [ 0 ] ) { r e t . s h i f t ( ) } d o n e = j Q u e r y . m e r g e ( d o n e , r e t ) ; r = r e t = [ c o n t e x t ] ; t = "   " + t . s u b s t r ( 1 , t . l e n g t h ) } e l s e { v a r   r e 2 = q u i c k I D ; v a r   m = r e 2 . e x e c ( t ) ; i f ( m ) { m = [ 0 , m [ 2 ] , m [ 3 ] , m [ 1 ] ] } e l s e { r e 2 = q u i c k C l a s s ; m = r e 2 . e x e c ( t ) } m [ 2 ] = m [ 2 ] . r e p l a c e ( / \ \ / g , " " ) ; v a r   e l e m = r e t [ r e t . l e n g t h - 1 ] ; i f ( m [ 1 ] = = " # " & & e l e m & & e l e m . g e t E l e m e n t B y I d & & ! j Q u e r y . i s X M L D o c ( e l e m ) ) { v a r   o i d = e l e m . g e t E l e m e n t B y I d ( m [ 2 ] ) ; i f ( ( j Q u e r y . b r o w s e r . m s i e | | j Q u e r y . b r o w s e r . o p e r a ) & & o i d & & t y p e o f   o i d . i d = = " s t r i n g " & & o i d . i d ! = m [ 2 ] ) { o i d = j Q u e r y ( ' [ @ i d = " ' + m [ 2 ] + ' " ] ' , e l e m ) [ 0 ] } r e t = r = o i d & & ( ! m [ 3 ] | | j Q u e r y . n o d e N a m e ( o i d , m [ 3 ] ) ) ? [ o i d ] : [ ] } e l s e { f o r ( v a r   i = 0 ; r e t [ i ] ; i + + ) { v a r   t a g = m [ 1 ] = = " # " & & m [ 3 ] ? m [ 3 ] : m [ 1 ] ! = " " | | m [ 0 ] = = " " ? " * " : m [ 2 ] ; i f ( t a g = = " * " & & r e t [ i ] . n o d e N a m e . t o L o w e r C a s e ( ) = = " o b j e c t " ) { t a g = " p a r a m " } r = j Q u e r y . m e r g e ( r , r e t [ i ] . g e t E l e m e n t s B y T a g N a m e ( t a g ) ) } i f ( m [ 1 ] = = " . " ) { r = j Q u e r y . c l a s s F i l t e r ( r , m [ 2 ] ) } i f ( m [ 1 ] = = " # " ) { v a r   t m p = [ ] ; f o r ( v a r   i = 0 ; r [ i ] ; i + + ) { i f ( r [ i ] . g e t A t t r i b u t e ( " i d " ) = = m [ 2 ] ) { t m p = [ r [ i ] ] ; b r e a k } } r = t m p } r e t = r } t = t . r e p l a c e ( r e 2 , " " ) } } i f ( t ) { v a r   v a l = j Q u e r y . f i l t e r ( t , r ) ; r e t = r = v a l . r ; t = j Q u e r y . t r i m ( v a l . t ) } } i f ( t ) { r e t = [ ] } i f ( r e t & & c o n t e x t = = r e t [ 0 ] ) { r e t . s h i f t ( ) } d o n e = j Q u e r y . m e r g e ( d o n e , r e t ) ; r e t u r n   d o n e } , c l a s s F i l t e r : f u n c t i o n ( r , m , n o t ) { m = "   " + m + "   " ; v a r   t m p = [ ] ; f o r ( v a r   i = 0 ; r [ i ] ; i + + ) { v a r   p a s s = ( "   " + r [ i ] . c l a s s N a m e + "   " ) . i n d e x O f ( m ) > = 0 ; i f ( ! n o t & & p a s s | | n o t & & ! p a s s ) { t m p . p u s h ( r [ i ] ) } } r e t u r n   t m p } , f i l t e r : f u n c t i o n ( t , r , n o t ) { v a r   l a s t ; w h i l e ( t & & t ! = l a s t ) { l a s t = t ; v a r   p = j Q u e r y . p a r s e , m ; f o r ( v a r   i = 0 ; p [ i ] ; i + + ) { m = p [ i ] . e x e c ( t ) ; i f ( m ) { t = t . s u b s t r i n g ( m [ 0 ] . l e n g t h ) ; m [ 2 ] = m [ 2 ] . r e p l a c e ( / \ \ / g , " " ) ; b r e a k } } i f ( ! m ) { b r e a k } i f ( m [ 1 ] = = " : " & & m [ 2 ] = = " n o t " ) { r = i s S i m p l e . t e s t ( m [ 3 ] ) ? j Q u e r y . f i l t e r ( m [ 3 ] , r , t r u e ) . r : j Q u e r y ( r ) . n o t ( m [ 3 ] ) } e l s e { i f ( m [ 1 ] = = " . " ) { r = j Q u e r y . c l a s s F i l t e r ( r , m [ 2 ] , n o t ) } e l s e { i f ( m [ 1 ] = = " [ " ) { v a r   t m p = [ ] , t y p e = m [ 3 ] ; f o r ( v a r   i = 0 , r l = r . l e n g t h ; i < r l ; i + + ) { v a r   a = r [ i ] , z = a [ j Q u e r y . p r o p s [ m [ 2 ] ] | | m [ 2 ] ] ; i f ( z = = n u l l | | / h r e f | s r c | s e l e c t e d / . t e s t ( m [ 2 ] ) ) { z = j Q u e r y . a t t r ( a , m [ 2 ] ) | | " " } i f ( ( t y p e = = " " & & ! ! z | | t y p e = = " = " & & z = = m [ 5 ] | | t y p e = = " ! = " & & z ! = m [ 5 ] | | t y p e = = " ^ = " & & z & & ! z . i n d e x O f ( m [ 5 ] ) | | t y p e = = " $ = " & & z . s u b s t r ( z . l e n g t h - m [ 5 ] . l e n g t h ) = = m [ 5 ] | | ( t y p e = = " * = " | | t y p e = = " ~ = " ) & & z . i n d e x O f ( m [ 5 ] ) > = 0 ) ^ n o t ) { t m p . p u s h ( a ) } } r = t m p } e l s e { i f ( m [ 1 ] = = " : " & & m [ 2 ] = = " n t h - c h i l d " ) { v a r   m e r g e = { } , t m p = [ ] , t e s t = / ( - ? ) ( \ d * ) n ( ( ? : \ + | - ) ? \ d * ) / . e x e c ( m [ 3 ] = = " e v e n " & & " 2 n " | | m [ 3 ] = = " o d d " & & " 2 n + 1 " | | ! / \ D / . t e s t ( m [ 3 ] ) & & " 0 n + " + m [ 3 ] | | m [ 3 ] ) , f i r s t = ( t e s t [ 1 ] + ( t e s t [ 2 ] | | 1 ) ) - 0 , l a s t = t e s t [ 3 ] - 0 ; f o r ( v a r   i = 0 , r l = r . l e n g t h ; i < r l ; i + + ) { v a r   n o d e = r [ i ] , p a r e n t N o d e = n o d e . p a r e n t N o d e , i d = j Q u e r y . d a t a ( p a r e n t N o d e ) ; i f ( ! m e r g e [ i d ] ) { v a r   c = 1 ; f o r ( v a r   n = p a r e n t N o d e . f i r s t C h i l d ; n ; n = n . n e x t S i b l i n g ) { i f ( n . n o d e T y p e = = 1 ) { n . n o d e I n d e x = c + + } } m e r g e [ i d ] = t r u e } v a r   a d d = f a l s e ; i f ( f i r s t = = 0 ) { i f ( n o d e . n o d e I n d e x = = l a s t ) { a d d = t r u e } } e l s e { i f ( ( n o d e . n o d e I n d e x - l a s t ) % f i r s t = = 0 & & ( n o d e . n o d e I n d e x - l a s t ) / f i r s t > = 0 ) { a d d = t r u e } } i f ( a d d ^ n o t ) { t m p . p u s h ( n o d e ) } } r = t m p } e l s e { v a r   f n = j Q u e r y . e x p r [ m [ 1 ] ] ; i f ( t y p e o f   f n = = " o b j e c t " ) { f n = f n [ m [ 2 ] ] } i f ( t y p e o f   f n = = " s t r i n g " ) { f n = e v a l ( " f a l s e | | f u n c t i o n ( a , i ) { r e t u r n   " + f n + " ; } " ) } r = j Q u e r y . g r e p ( r , f u n c t i o n ( e l e m , i ) { r e t u r n   f n ( e l e m , i , m , r ) } , n o t ) } } } } } r e t u r n { r : r , t : t } } , d i r : f u n c t i o n ( e l e m , d i r ) { v a r   m a t c h e d = [ ] , c u r = e l e m [ d i r ] ; w h i l e ( c u r & & c u r ! = d o c u m e n t ) { i f ( c u r . n o d e T y p e = = 1 ) { m a t c h e d . p u s h ( c u r ) } c u r = c u r [ d i r ] } r e t u r n   m a t c h e d } , n t h : f u n c t i o n ( c u r , r e s u l t , d i r , e l e m ) { r e s u l t = r e s u l t | | 1 ; v a r   n u m = 0 ; f o r ( ; c u r ; c u r = c u r [ d i r ] ) { i f ( c u r . n o d e T y p e = = 1 & & + + n u m = = r e s u l t ) { b r e a k } } r e t u r n   c u r } , s i b l i n g : f u n c t i o n ( n , e l e m ) { v a r   r = [ ] ; f o r ( ; n ; n = n . n e x t S i b l i n g ) { i f ( n . n o d e T y p e = = 1 & & n ! = e l e m ) { r . p u s h ( n ) } } r e t u r n   r } } ) ; j Q u e r y . e v e n t = { a d d : f u n c t i o n ( e l e m , t y p e s , h a n d l e r , d a t a ) { i f ( e l e m . n o d e T y p e = = 3 | | e l e m . n o d e T y p e = = 8 ) { r e t u r n   } i f ( j Q u e r y . b r o w s e r . m s i e & & e l e m . s e t I n t e r v a l ) { e l e m = w i n d o w } i f ( ! h a n d l e r . g u i d ) { h a n d l e r . g u i d = t h i s . g u i d + + } i f ( d a t a ! = u n d e f i n e d ) { v a r   f n = h a n d l e r ; h a n d l e r = t h i s . p r o x y ( f n , f u n c t i o n ( ) { r e t u r n   f n . a p p l y ( t h i s , a r g u m e n t s ) } ) ; h a n d l e r . d a t a = d a t a } v a r   e v e n t s = j Q u e r y . d a t a ( e l e m , " e v e n t s " ) | | j Q u e r y . d a t a ( e l e m , " e v e n t s " , { } ) , h a n d l e = j Q u e r y . d a t a ( e l e m , " h a n d l e " ) | | j Q u e r y . d a t a ( e l e m , " h a n d l e " , f u n c t i o n ( ) { i f ( t y p e o f   j Q u e r y ! = " u n d e f i n e d " & & ! j Q u e r y . e v e n t . t r i g g e r e d ) { r e t u r n   j Q u e r y . e v e n t . h a n d l e . a p p l y ( a r g u m e n t s . c a l l e e . e l e m , a r g u m e n t s ) } } ) ; h a n d l e . e l e m = e l e m ; j Q u e r y . e a c h ( t y p e s . s p l i t ( / \ s + / ) , f u n c t i o n ( i n d e x , t y p e ) { v a r   p a r t s = t y p e . s p l i t ( " . " ) ; t y p e = p a r t s [ 0 ] ; h a n d l e r . t y p e = p a r t s [ 1 ] ; v a r   h a n d l e r s = e v e n t s [ t y p e ] ; i f ( ! h a n d l e r s ) { h a n d l e r s = e v e n t s [ t y p e ] = { } ; i f ( ! j Q u e r y . e v e n t . s p e c i a l [ t y p e ] | | j Q u e r y . e v e n t . s p e c i a l [ t y p e ] . s e t u p . c a l l ( e l e m ) = = = f a l s e ) { i f ( e l e m . a d d E v e n t L i s t e n e r ) { e l e m . a d d E v e n t L i s t e n e r ( t y p e , h a n d l e , f a l s e ) } e l s e { i f ( e l e m . a t t a c h E v e n t ) { e l e m . a t t a c h E v e n t ( " o n " + t y p e , h a n d l e ) } } } } h a n d l e r s [ h a n d l e r . g u i d ] = h a n d l e r ; j Q u e r y . e v e n t . g l o b a l [ t y p e ] = t r u e } ) ; e l e m = n u l l } , g u i d : 1 , g l o b a l : { } , r e m o v e : f u n c t i o n ( e l e m , t y p e s , h a n d l e r ) { i f ( e l e m . n o d e T y p e = = 3 | | e l e m . n o d e T y p e = = 8 ) { r e t u r n   } v a r   e v e n t s = j Q u e r y . d a t a ( e l e m , " e v e n t s " ) , r e t , i n d e x ; i f ( e v e n t s ) { i f ( t y p e s = = u n d e f i n e d | | ( t y p e o f   t y p e s = = " s t r i n g " & & t y p e s . c h a r A t ( 0 ) = = " . " ) ) { f o r ( v a r   t y p e   i n   e v e n t s ) { t h i s . r e m o v e ( e l e m , t y p e + ( t y p e s | | " " ) ) } } e l s e { i f ( t y p e s . t y p e ) { h a n d l e r = t y p e s . h a n d l e r ; t y p e s = t y p e s . t y p e } j Q u e r y . e a c h ( t y p e s . s p l i t ( / \ s + / ) , f u n c t i o n ( i n d e x , t y p e ) { v a r   p a r t s = t y p e . s p l i t ( " . " ) ; t y p e = p a r t s [ 0 ] ; i f ( e v e n t s [ t y p e ] ) { i f ( h a n d l e r ) { d e l e t e   e v e n t s [ t y p e ] [ h a n d l e r . g u i d ] } e l s e { f o r ( h a n d l e r   i n   e v e n t s [ t y p e ] ) { i f ( ! p a r t s [ 1 ] | | e v e n t s [ t y p e ] [ h a n d l e r ] . t y p e = = p a r t s [ 1 ] ) { d e l e t e   e v e n t s [ t y p e ] [ h a n d l e r ] } } } f o r ( r e t   i n   e v e n t s [ t y p e ] ) { b r e a k } i f ( ! r e t ) { i f ( ! j Q u e r y . e v e n t . s p e c i a l [ t y p e ] | | j Q u e r y . e v e n t . s p e c i a l [ t y p e ] . t e a r d o w n . c a l l ( e l e m ) = = = f a l s e ) { i f ( e l e m . r e m o v e E v e n t L i s t e n e r ) { e l e m . r e m o v e E v e n t L i s t e n e r ( t y p e , j Q u e r y . d a t a ( e l e m , " h a n d l e " ) , f a l s e ) } e l s e { i f ( e l e m . d e t a c h E v e n t ) { e l e m . d e t a c h E v e n t ( " o n " + t y p e , j Q u e r y . d a t a ( e l e m , " h a n d l e " ) ) } } } r e t = n u l l ; d e l e t e   e v e n t s [ t y p e ] } } } ) } f o r ( r e t   i n   e v e n t s ) { b r e a k } i f ( ! r e t ) { v a r   h a n d l e = j Q u e r y . d a t a ( e l e m , " h a n d l e " ) ; i f ( h a n d l e ) { h a n d l e . e l e m = n u l l } j Q u e r y . r e m o v e D a t a ( e l e m , " e v e n t s " ) ; j Q u e r y . r e m o v e D a t a ( e l e m , " h a n d l e " ) } } } , t r i g g e r : f u n c t i o n ( t y p e , d a t a , e l e m , d o n a t i v e , e x t r a ) { d a t a = j Q u e r y . m a k e A r r a y ( d a t a ) ; i f ( t y p e . i n d e x O f ( " ! " ) > = 0 ) { t y p e = t y p e . s l i c e ( 0 , - 1 ) ; v a r   e x c l u s i v e = t r u e } i f ( ! e l e m ) { i f ( t h i s . g l o b a l [ t y p e ] ) { j Q u e r y ( " * " ) . a d d ( [ w i n d o w , d o c u m e n t ] ) . t r i g g e r ( t y p e , d a t a ) } } e l s e { i f ( e l e m . n o d e T y p e = = 3 | | e l e m . n o d e T y p e = = 8 ) { r e t u r n   u n d e f i n e d } v a r   v a l , r e t , f n = j Q u e r y . i s F u n c t i o n ( e l e m [ t y p e ] | | n u l l ) , e v e n t = ! d a t a [ 0 ] | | ! d a t a [ 0 ] . p r e v e n t D e f a u l t ; i f ( e v e n t ) { d a t a . u n s h i f t ( { t y p e : t y p e , t a r g e t : e l e m , p r e v e n t D e f a u l t : f u n c t i o n ( ) { } , s t o p P r o p a g a t i o n : f u n c t i o n ( ) { } , t i m e S t a m p : n o w ( ) } ) ; d a t a [ 0 ] [ e x p a n d o ] = t r u e } d a t a [ 0 ] . t y p e = t y p e ; i f ( e x c l u s i v e ) { d a t a [ 0 ] . e x c l u s i v e = t r u e } v a r   h a n d l e = j Q u e r y . d a t a ( e l e m , " h a n d l e " ) ; i f ( h a n d l e ) { v a l = h a n d l e . a p p l y ( e l e m , d a t a ) } i f ( ( ! f n | | ( j Q u e r y . n o d e N a m e ( e l e m , " a " ) & & t y p e = = " c l i c k " ) ) & & e l e m [ " o n " + t y p e ] & & e l e m [ " o n " + t y p e ] . a p p l y ( e l e m , d a t a ) = = = f a l s e ) { v a l = f a l s e } i f ( e v e n t ) { d a t a . s h i f t ( ) } i f ( e x t r a & & j Q u e r y . i s F u n c t i o n ( e x t r a ) ) { r e t = e x t r a . a p p l y ( e l e m , v a l = = n u l l ? d a t a : d a t a . c o n c a t ( v a l ) ) ; i f ( r e t ! = = u n d e f i n e d ) { v a l = r e t } } i f ( f n & & d o n a t i v e ! = = f a l s e & & v a l ! = = f a l s e & & ! ( j Q u e r y . n o d e N a m e ( e l e m , " a " ) & & t y p e = = " c l i c k " ) ) { t h i s . t r i g g e r e d = t r u e ; t r y { e l e m [ t y p e ] ( ) } c a t c h ( e ) { } } t h i s . t r i g g e r e d = f a l s e } r e t u r n   v a l } , h a n d l e : f u n c t i o n ( e v e n t ) { v a r   v a l , r e t , n a m e s p a c e , a l l , h a n d l e r s ; e v e n t = a r g u m e n t s [ 0 ] = j Q u e r y . e v e n t . f i x ( e v e n t | | w i n d o w . e v e n t ) ; n a m e s p a c e = e v e n t . t y p e . s p l i t ( " . " ) ; e v e n t . t y p e = n a m e s p a c e [ 0 ] ; n a m e s p a c e = n a m e s p a c e [ 1 ] ; a l l = ! n a m e s p a c e & & ! e v e n t . e x c l u s i v e ; h a n d l e r s = ( j Q u e r y . d a t a ( t h i s , " e v e n t s " ) | | { } ) [ e v e n t . t y p e ] ; f o r ( v a r   j   i n   h a n d l e r s ) { v a r   h a n d l e r = h a n d l e r s [ j ] ; i f ( a l l | | h a n d l e r . t y p e = = n a m e s p a c e ) { e v e n t . h a n d l e r = h a n d l e r ; e v e n t . d a t a = h a n d l e r . d a t a ; r e t = h a n d l e r . a p p l y ( t h i s , a r g u m e n t s ) ; i f ( v a l ! = = f a l s e ) { v a l = r e t } i f ( r e t = = = f a l s e ) { e v e n t . p r e v e n t D e f a u l t ( ) ; e v e n t . s t o p P r o p a g a t i o n ( ) } } } r e t u r n   v a l } , f i x : f u n c t i o n ( e v e n t ) { i f ( e v e n t [ e x p a n d o ] = = t r u e ) { r e t u r n   e v e n t } v a r   o r i g i n a l E v e n t = e v e n t ; e v e n t = { o r i g i n a l E v e n t : o r i g i n a l E v e n t } ; v a r   p r o p s = " a l t K e y   a t t r C h a n g e   a t t r N a m e   b u b b l e s   b u t t o n   c a n c e l a b l e   c h a r C o d e   c l i e n t X   c l i e n t Y   c t r l K e y   c u r r e n t T a r g e t   d a t a   d e t a i l   e v e n t P h a s e   f r o m E l e m e n t   h a n d l e r   k e y C o d e   m e t a K e y   n e w V a l u e   o r i g i n a l T a r g e t   p a g e X   p a g e Y   p r e v V a l u e   r e l a t e d N o d e   r e l a t e d T a r g e t   s c r e e n X   s c r e e n Y   s h i f t K e y   s r c E l e m e n t   t a r g e t   t i m e S t a m p   t o E l e m e n t   t y p e   v i e w   w h e e l D e l t a   w h i c h " . s p l i t ( "   " ) ; f o r ( v a r   i = p r o p s . l e n g t h ; i ; i - - ) { e v e n t [ p r o p s [ i ] ] = o r i g i n a l E v e n t [ p r o p s [ i ] ] } e v e n t [ e x p a n d o ] = t r u e ; e v e n t . p r e v e n t D e f a u l t = f u n c t i o n ( ) { i f ( o r i g i n a l E v e n t . p r e v e n t D e f a u l t ) { o r i g i n a l E v e n t . p r e v e n t D e f a u l t ( ) } o r i g i n a l E v e n t . r e t u r n V a l u e = f a l s e } ; e v e n t . s t o p P r o p a g a t i o n = f u n c t i o n ( ) { i f ( o r i g i n a l E v e n t . s t o p P r o p a g a t i o n ) { o r i g i n a l E v e n t . s t o p P r o p a g a t i o n ( ) } o r i g i n a l E v e n t . c a n c e l B u b b l e = t r u e } ; e v e n t . t i m e S t a m p = e v e n t . t i m e S t a m p | | n o w ( ) ; i f ( ! e v e n t . t a r g e t ) { e v e n t . t a r g e t = e v e n t . s r c E l e m e n t | | d o c u m e n t } i f ( e v e n t . t a r g e t . n o d e T y p e = = 3 ) { e v e n t . t a r g e t = e v e n t . t a r g e t . p a r e n t N o d e } i f ( ! e v e n t . r e l a t e d T a r g e t & & e v e n t . f r o m E l e m e n t ) { e v e n t . r e l a t e d T a r g e t = e v e n t . f r o m E l e m e n t = = e v e n t . t a r g e t ? e v e n t . t o E l e m e n t : e v e n t . f r o m E l e m e n t } i f ( e v e n t . p a g e X = = n u l l & & e v e n t . c l i e n t X ! = n u l l ) { v a r   d o c = d o c u m e n t . d o c u m e n t E l e m e n t , b o d y = d o c u m e n t . b o d y ; e v e n t . p a g e X = e v e n t . c l i e n t X + ( d o c & & d o c . s c r o l l L e f t | | b o d y & & b o d y . s c r o l l L e f t | | 0 ) - ( d o c . c l i e n t L e f t | | 0 ) ; e v e n t . p a g e Y = e v e n t . c l i e n t Y + ( d o c & & d o c . s c r o l l T o p | | b o d y & & b o d y . s c r o l l T o p | | 0 ) - ( d o c . c l i e n t T o p | | 0 ) } i f ( ! e v e n t . w h i c h & & ( ( e v e n t . c h a r C o d e | | e v e n t . c h a r C o d e = = = 0 ) ? e v e n t . c h a r C o d e : e v e n t . k e y C o d e ) ) { e v e n t . w h i c h = e v e n t . c h a r C o d e | | e v e n t . k e y C o d e } i f ( ! e v e n t . m e t a K e y & & e v e n t . c t r l K e y ) { e v e n t . m e t a K e y = e v e n t . c t r l K e y } i f ( ! e v e n t . w h i c h & & e v e n t . b u t t o n ) { e v e n t . w h i c h = ( e v e n t . b u t t o n & 1 ? 1 : ( e v e n t . b u t t o n & 2 ? 3 : ( e v e n t . b u t t o n & 4 ? 2 : 0 ) ) ) } r e t u r n   e v e n t } , p r o x y : f u n c t i o n ( f n , p r o x y ) { p r o x y . g u i d = f n . g u i d = f n . g u i d | | p r o x y . g u i d | | t h i s . g u i d + + ; r e t u r n   p r o x y } , s p e c i a l : { r e a d y : { s e t u p : f u n c t i o n ( ) { b i n d R e a d y ( ) ; r e t u r n   } , t e a r d o w n : f u n c t i o n ( ) { r e t u r n   } } , m o u s e e n t e r : { s e t u p : f u n c t i o n ( ) { i f ( j Q u e r y . b r o w s e r . m s i e ) { r e t u r n   f a l s e } j Q u e r y ( t h i s ) . b i n d ( " m o u s e o v e r " , j Q u e r y . e v e n t . s p e c i a l . m o u s e e n t e r . h a n d l e r ) ; r e t u r n   t r u e } , t e a r d o w n : f u n c t i o n ( ) { i f ( j Q u e r y . b r o w s e r . m s i e ) { r e t u r n   f a l s e } j Q u e r y ( t h i s ) . u n b i n d ( " m o u s e o v e r " , j Q u e r y . e v e n t . s p e c i a l . m o u s e e n t e r . h a n d l e r ) ; r e t u r n   t r u e } , h a n d l e r : f u n c t i o n ( e v e n t ) { i f ( w i t h i n E l e m e n t ( e v e n t , t h i s ) ) { r e t u r n   t r u e } e v e n t . t y p e = " m o u s e e n t e r " ; r e t u r n   j Q u e r y . e v e n t . h a n d l e . a p p l y ( t h i s , a r g u m e n t s ) } } , m o u s e l e a v e : { s e t u p : f u n c t i o n ( ) { i f ( j Q u e r y . b r o w s e r . m s i e ) { r e t u r n   f a l s e } j Q u e r y ( t h i s ) . b i n d ( " m o u s e o u t " , j Q u e r y . e v e n t . s p e c i a l . m o u s e l e a v e . h a n d l e r ) ; r e t u r n   t r u e } , t e a r d o w n : f u n c t i o n ( ) { i f ( j Q u e r y . b r o w s e r . m s i e ) { r e t u r n   f a l s e } j Q u e r y ( t h i s ) . u n b i n d ( " m o u s e o u t " , j Q u e r y . e v e n t . s p e c i a l . m o u s e l e a v e . h a n d l e r ) ; r e t u r n   t r u e } , h a n d l e r : f u n c t i o n ( e v e n t ) { i f ( w i t h i n E l e m e n t ( e v e n t , t h i s ) ) { r e t u r n   t r u e } e v e n t . t y p e = " m o u s e l e a v e " ; r e t u r n   j Q u e r y . e v e n t . h a n d l e . a p p l y ( t h i s , a r g u m e n t s ) } } } } ; j Q u e r y . f n . e x t e n d ( { b i n d : f u n c t i o n ( t y p e , d a t a , f n ) { r e t u r n   t y p e = = " u n l o a d " ? t h i s . o n e ( t y p e , d a t a , f n ) : t h i s . e a c h ( f u n c t i o n ( ) { j Q u e r y . e v e n t . a d d ( t h i s , t y p e , f n | | d a t a , f n & & d a t a ) } ) } , o n e : f u n c t i o n ( t y p e , d a t a , f n ) { v a r   o n e = j Q u e r y . e v e n t . p r o x y ( f n | | d a t a , f u n c t i o n ( e v e n t ) { j Q u e r y ( t h i s ) . u n b i n d ( e v e n t , o n e ) ; r e t u r n ( f n | | d a t a ) . a p p l y ( t h i s , a r g u m e n t s ) } ) ; r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { j Q u e r y . e v e n t . a d d ( t h i s , t y p e , o n e , f n & & d a t a ) } ) } , u n b i n d : f u n c t i o n ( t y p e , f n ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { j Q u e r y . e v e n t . r e m o v e ( t h i s , t y p e , f n ) } ) } , t r i g g e r : f u n c t i o n ( t y p e , d a t a , f n ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { j Q u e r y . e v e n t . t r i g g e r ( t y p e , d a t a , t h i s , t r u e , f n ) } ) } , t r i g g e r H a n d l e r : f u n c t i o n ( t y p e , d a t a , f n ) { r e t u r n   t h i s [ 0 ] & & j Q u e r y . e v e n t . t r i g g e r ( t y p e , d a t a , t h i s [ 0 ] , f a l s e , f n ) } , t o g g l e : f u n c t i o n ( f n ) { v a r   a r g s = a r g u m e n t s , i = 1 ; w h i l e ( i < a r g s . l e n g t h ) { j Q u e r y . e v e n t . p r o x y ( f n , a r g s [ i + + ] ) } r e t u r n   t h i s . c l i c k ( j Q u e r y . e v e n t . p r o x y ( f n , f u n c t i o n ( e v e n t ) { t h i s . l a s t T o g g l e = ( t h i s . l a s t T o g g l e | | 0 ) % i ; e v e n t . p r e v e n t D e f a u l t ( ) ; r e t u r n   a r g s [ t h i s . l a s t T o g g l e + + ] . a p p l y ( t h i s , a r g u m e n t s ) | | f a l s e } ) ) } , h o v e r : f u n c t i o n ( f n O v e r , f n O u t ) { r e t u r n   t h i s . b i n d ( " m o u s e e n t e r " , f n O v e r ) . b i n d ( " m o u s e l e a v e " , f n O u t ) } , r e a d y : f u n c t i o n ( f n ) { b i n d R e a d y ( ) ; i f ( j Q u e r y . i s R e a d y ) { f n . c a l l ( d o c u m e n t , j Q u e r y ) } e l s e { j Q u e r y . r e a d y L i s t . p u s h ( f u n c t i o n ( ) { r e t u r n   f n . c a l l ( t h i s , j Q u e r y ) } ) } r e t u r n   t h i s } } ) ; j Q u e r y . e x t e n d ( { i s R e a d y : f a l s e , r e a d y L i s t : [ ] , r e a d y : f u n c t i o n ( ) { i f ( ! j Q u e r y . i s R e a d y ) { j Q u e r y . i s R e a d y = t r u e ; i f ( j Q u e r y . r e a d y L i s t ) { j Q u e r y . e a c h ( j Q u e r y . r e a d y L i s t , f u n c t i o n ( ) { t h i s . c a l l ( d o c u m e n t ) } ) ; j Q u e r y . r e a d y L i s t = n u l l } j Q u e r y ( d o c u m e n t ) . t r i g g e r H a n d l e r ( " r e a d y " ) } } } ) ; v a r   r e a d y B o u n d = f a l s e ; f u n c t i o n   b i n d R e a d y ( ) { i f ( r e a d y B o u n d ) { r e t u r n   } r e a d y B o u n d = t r u e ; i f ( d o c u m e n t . a d d E v e n t L i s t e n e r & & ! j Q u e r y . b r o w s e r . o p e r a ) { d o c u m e n t . a d d E v e n t L i s t e n e r ( " D O M C o n t e n t L o a d e d " , j Q u e r y . r e a d y , f a l s e ) } i f ( j Q u e r y . b r o w s e r . m s i e & & w i n d o w = = t o p ) { ( f u n c t i o n ( ) { i f ( j Q u e r y . i s R e a d y ) { r e t u r n   } t r y { d o c u m e n t . d o c u m e n t E l e m e n t . d o S c r o l l ( " l e f t " ) } c a t c h ( e r r o r ) { s e t T i m e o u t ( a r g u m e n t s . c a l l e e , 0 ) ; r e t u r n   } j Q u e r y . r e a d y ( ) } ) ( ) } i f ( j Q u e r y . b r o w s e r . o p e r a ) { d o c u m e n t . a d d E v e n t L i s t e n e r ( " D O M C o n t e n t L o a d e d " , f u n c t i o n ( ) { i f ( j Q u e r y . i s R e a d y ) { r e t u r n   } f o r ( v a r   i = 0 ; i < d o c u m e n t . s t y l e S h e e t s . l e n g t h ; i + + ) { i f ( d o c u m e n t . s t y l e S h e e t s [ i ] . d i s a b l e d ) { s e t T i m e o u t ( a r g u m e n t s . c a l l e e , 0 ) ; r e t u r n   } } j Q u e r y . r e a d y ( ) } , f a l s e ) } i f ( j Q u e r y . b r o w s e r . s a f a r i ) { v a r   n u m S t y l e s ; ( f u n c t i o n ( ) { i f ( j Q u e r y . i s R e a d y ) { r e t u r n   } i f ( d o c u m e n t . r e a d y S t a t e ! = " l o a d e d " & & d o c u m e n t . r e a d y S t a t e ! = " c o m p l e t e " ) { s e t T i m e o u t ( a r g u m e n t s . c a l l e e , 0 ) ; r e t u r n   } i f ( n u m S t y l e s = = = u n d e f i n e d ) { n u m S t y l e s = j Q u e r y ( " s t y l e ,   l i n k [ r e l = s t y l e s h e e t ] " ) . l e n g t h } i f ( d o c u m e n t . s t y l e S h e e t s . l e n g t h ! = n u m S t y l e s ) { s e t T i m e o u t ( a r g u m e n t s . c a l l e e , 0 ) ; r e t u r n   } j Q u e r y . r e a d y ( ) } ) ( ) } j Q u e r y . e v e n t . a d d ( w i n d o w , " l o a d " , j Q u e r y . r e a d y ) } j Q u e r y . e a c h ( ( " b l u r , f o c u s , l o a d , r e s i z e , s c r o l l , u n l o a d , c l i c k , d b l c l i c k , m o u s e d o w n , m o u s e u p , m o u s e m o v e , m o u s e o v e r , m o u s e o u t , c h a n g e , s e l e c t , s u b m i t , k e y d o w n , k e y p r e s s , k e y u p , e r r o r " ) . s p l i t ( " , " ) , f u n c t i o n ( i , n a m e ) { j Q u e r y . f n [ n a m e ] = f u n c t i o n ( f n ) { r e t u r n   f n ? t h i s . b i n d ( n a m e , f n ) : t h i s . t r i g g e r ( n a m e ) } } ) ; v a r   w i t h i n E l e m e n t = f u n c t i o n ( e v e n t , e l e m ) { v a r   p a r e n t = e v e n t . r e l a t e d T a r g e t ; w h i l e ( p a r e n t & & p a r e n t ! = e l e m ) { t r y { p a r e n t = p a r e n t . p a r e n t N o d e } c a t c h ( e r r o r ) { p a r e n t = e l e m } } r e t u r n   p a r e n t = = e l e m } ; j Q u e r y ( w i n d o w ) . b i n d ( " u n l o a d " , f u n c t i o n ( ) { j Q u e r y ( " * " ) . a d d ( d o c u m e n t ) . u n b i n d ( ) } ) ; j Q u e r y . f n . e x t e n d ( { _ l o a d : j Q u e r y . f n . l o a d , l o a d : f u n c t i o n ( u r l , p a r a m s , c a l l b a c k ) { i f ( t y p e o f   u r l ! = " s t r i n g " ) { r e t u r n   t h i s . _ l o a d ( u r l ) } v a r   o f f = u r l . i n d e x O f ( "   " ) ; i f ( o f f > = 0 ) { v a r   s e l e c t o r = u r l . s l i c e ( o f f , u r l . l e n g t h ) ; u r l = u r l . s l i c e ( 0 , o f f ) } c a l l b a c k = c a l l b a c k | | f u n c t i o n ( ) { } ; v a r   t y p e = " G E T " ; i f ( p a r a m s ) { i f ( j Q u e r y . i s F u n c t i o n ( p a r a m s ) ) { c a l l b a c k = p a r a m s ; p a r a m s = n u l l } e l s e { p a r a m s = j Q u e r y . p a r a m ( p a r a m s ) ; t y p e = " P O S T " } } v a r   s e l f = t h i s ; j Q u e r y . a j a x ( { u r l : u r l , t y p e : t y p e , d a t a T y p e : " h t m l " , d a t a : p a r a m s , c o m p l e t e : f u n c t i o n ( r e s , s t a t u s ) { i f ( s t a t u s = = " s u c c e s s " | | s t a t u s = = " n o t m o d i f i e d " ) { s e l f . h t m l ( s e l e c t o r ? j Q u e r y ( " < d i v / > " ) . a p p e n d ( r e s . r e s p o n s e T e x t . r e p l a c e ( / < s c r i p t ( . | \ s ) * ? \ / s c r i p t > / g , " " ) ) . f i n d ( s e l e c t o r ) : r e s . r e s p o n s e T e x t ) } s e l f . e a c h ( c a l l b a c k , [ r e s . r e s p o n s e T e x t , s t a t u s , r e s ] ) } } ) ; r e t u r n   t h i s } , s e r i a l i z e : f u n c t i o n ( ) { r e t u r n   j Q u e r y . p a r a m ( t h i s . s e r i a l i z e A r r a y ( ) ) } , s e r i a l i z e A r r a y : f u n c t i o n ( ) { r e t u r n   t h i s . m a p ( f u n c t i o n ( ) { r e t u r n   j Q u e r y . n o d e N a m e ( t h i s , " f o r m " ) ? j Q u e r y . m a k e A r r a y ( t h i s . e l e m e n t s ) : t h i s } ) . f i l t e r ( f u n c t i o n ( ) { r e t u r n   t h i s . n a m e & & ! t h i s . d i s a b l e d & & ( t h i s . c h e c k e d | | / s e l e c t | t e x t a r e a / i . t e s t ( t h i s . n o d e N a m e ) | | / t e x t | h i d d e n | p a s s w o r d / i . t e s t ( t h i s . t y p e ) ) } ) . m a p ( f u n c t i o n ( i , e l e m ) { v a r   v a l = j Q u e r y ( t h i s ) . v a l ( ) ; r e t u r n   v a l = = n u l l ? n u l l : v a l . c o n s t r u c t o r = = A r r a y ? j Q u e r y . m a p ( v a l , f u n c t i o n ( v a l , i ) { r e t u r n { n a m e : e l e m . n a m e , v a l u e : v a l } } ) : { n a m e : e l e m . n a m e , v a l u e : v a l } } ) . g e t ( ) } } ) ; j Q u e r y . e a c h ( " a j a x S t a r t , a j a x S t o p , a j a x C o m p l e t e , a j a x E r r o r , a j a x S u c c e s s , a j a x S e n d " . s p l i t ( " , " ) , f u n c t i o n ( i , o ) { j Q u e r y . f n [ o ] = f u n c t i o n ( f ) { r e t u r n   t h i s . b i n d ( o , f ) } } ) ; v a r   j s c = n o w ( ) ; j Q u e r y . e x t e n d ( { g e t : f u n c t i o n ( u r l , d a t a , c a l l b a c k , t y p e ) { i f ( j Q u e r y . i s F u n c t i o n ( d a t a ) ) { c a l l b a c k = d a t a ; d a t a = n u l l } r e t u r n   j Q u e r y . a j a x ( { t y p e : " G E T " , u r l : u r l , d a t a : d a t a , s u c c e s s : c a l l b a c k , d a t a T y p e : t y p e } ) } , g e t S c r i p t : f u n c t i o n ( u r l , c a l l b a c k ) { r e t u r n   j Q u e r y . g e t ( u r l , n u l l , c a l l b a c k , " s c r i p t " ) } , g e t J S O N : f u n c t i o n ( u r l , d a t a , c a l l b a c k ) { r e t u r n   j Q u e r y . g e t ( u r l , d a t a , c a l l b a c k , " j s o n " ) } , p o s t : f u n c t i o n ( u r l , d a t a , c a l l b a c k , t y p e ) { i f ( j Q u e r y . i s F u n c t i o n ( d a t a ) ) { c a l l b a c k = d a t a ; d a t a = { } } r e t u r n   j Q u e r y . a j a x ( { t y p e : " P O S T " , u r l : u r l , d a t a : d a t a , s u c c e s s : c a l l b a c k , d a t a T y p e : t y p e } ) } , a j a x S e t u p : f u n c t i o n ( s e t t i n g s ) { j Q u e r y . e x t e n d ( j Q u e r y . a j a x S e t t i n g s , s e t t i n g s ) } , a j a x S e t t i n g s : { u r l : l o c a t i o n . h r e f , g l o b a l : t r u e , t y p e : " G E T " , t i m e o u t : 0 , c o n t e n t T y p e : " a p p l i c a t i o n / x - w w w - f o r m - u r l e n c o d e d " , p r o c e s s D a t a : t r u e , a s y n c : t r u e , d a t a : n u l l , u s e r n a m e : n u l l , p a s s w o r d : n u l l , a c c e p t s : { x m l : " a p p l i c a t i o n / x m l ,   t e x t / x m l " , h t m l : " t e x t / h t m l " , s c r i p t : " t e x t / j a v a s c r i p t ,   a p p l i c a t i o n / j a v a s c r i p t " , j s o n : " a p p l i c a t i o n / j s o n ,   t e x t / j a v a s c r i p t " , t e x t : " t e x t / p l a i n " , _ d e f a u l t : " * / * " } } , l a s t M o d i f i e d : { } , a j a x : f u n c t i o n ( s ) { s = j Q u e r y . e x t e n d ( t r u e , s , j Q u e r y . e x t e n d ( t r u e , { } , j Q u e r y . a j a x S e t t i n g s , s ) ) ; v a r   j s o n p , j s r e = / = \ ? ( & | $ ) / g , s t a t u s , d a t a , t y p e = s . t y p e . t o U p p e r C a s e ( ) ; i f ( s . d a t a & & s . p r o c e s s D a t a & & t y p e o f   s . d a t a ! = " s t r i n g " ) { s . d a t a = j Q u e r y . p a r a m ( s . d a t a ) } i f ( s . d a t a T y p e = = " j s o n p " ) { i f ( t y p e = = " G E T " ) { i f ( ! s . u r l . m a t c h ( j s r e ) ) { s . u r l + = ( s . u r l . m a t c h ( / \ ? / ) ? " & " : " ? " ) + ( s . j s o n p | | " c a l l b a c k " ) + " = ? " } } e l s e { i f ( ! s . d a t a | | ! s . d a t a . m a t c h ( j s r e ) ) { s . d a t a = ( s . d a t a ? s . d a t a + " & " : " " ) + ( s . j s o n p | | " c a l l b a c k " ) + " = ? " } } s . d a t a T y p e = " j s o n " } i f ( s . d a t a T y p e = = " j s o n " & & ( s . d a t a & & s . d a t a . m a t c h ( j s r e ) | | s . u r l . m a t c h ( j s r e ) ) ) { j s o n p = " j s o n p " + j s c + + ; i f ( s . d a t a ) { s . d a t a = ( s . d a t a + " " ) . r e p l a c e ( j s r e , " = " + j s o n p + " $ 1 " ) } s . u r l = s . u r l . r e p l a c e ( j s r e , " = " + j s o n p + " $ 1 " ) ; s . d a t a T y p e = " s c r i p t " ; w i n d o w [ j s o n p ] = f u n c t i o n ( t m p ) { d a t a = t m p ; s u c c e s s ( ) ; c o m p l e t e ( ) ; w i n d o w [ j s o n p ] = u n d e f i n e d ; t r y { d e l e t e   w i n d o w [ j s o n p ] } c a t c h ( e ) { } i f ( h e a d ) { h e a d . r e m o v e C h i l d ( s c r i p t ) } } } i f ( s . d a t a T y p e = = " s c r i p t " & & s . c a c h e = = n u l l ) { s . c a c h e = f a l s e } i f ( s . c a c h e = = = f a l s e & & t y p e = = " G E T " ) { v a r   t s = n o w ( ) ; v a r   r e t = s . u r l . r e p l a c e ( / ( \ ? | & ) _ = . * ? ( & | $ ) / , " $ 1 _ = " + t s + " $ 2 " ) ; s . u r l = r e t + ( ( r e t = = s . u r l ) ? ( s . u r l . m a t c h ( / \ ? / ) ? " & " : " ? " ) + " _ = " + t s : " " ) } i f ( s . d a t a & & t y p e = = " G E T " ) { s . u r l + = ( s . u r l . m a t c h ( / \ ? / ) ? " & " : " ? " ) + s . d a t a ; s . d a t a = n u l l } i f ( s . g l o b a l & & ! j Q u e r y . a c t i v e + + ) { j Q u e r y . e v e n t . t r i g g e r ( " a j a x S t a r t " ) } v a r   r e m o t e = / ^ ( ? : \ w + : ) ? \ / \ / ( [ ^ \ / ? # ] + ) / ; i f ( s . d a t a T y p e = = " s c r i p t " & & t y p e = = " G E T " & & r e m o t e . t e s t ( s . u r l ) & & r e m o t e . e x e c ( s . u r l ) [ 1 ] ! = l o c a t i o n . h o s t ) { v a r   h e a d = d o c u m e n t . g e t E l e m e n t s B y T a g N a m e ( " h e a d " ) [ 0 ] ; v a r   s c r i p t = d o c u m e n t . c r e a t e E l e m e n t ( " s c r i p t " ) ; s c r i p t . s r c = s . u r l ; i f ( s . s c r i p t C h a r s e t ) { s c r i p t . c h a r s e t = s . s c r i p t C h a r s e t } i f ( ! j s o n p ) { v a r   d o n e = f a l s e ; s c r i p t . o n l o a d = s c r i p t . o n r e a d y s t a t e c h a n g e = f u n c t i o n ( ) { i f ( ! d o n e & & ( ! t h i s . r e a d y S t a t e | | t h i s . r e a d y S t a t e = = " l o a d e d " | | t h i s . r e a d y S t a t e = = " c o m p l e t e " ) ) { d o n e = t r u e ; s u c c e s s ( ) ; c o m p l e t e ( ) ; h e a d . r e m o v e C h i l d ( s c r i p t ) } } } h e a d . a p p e n d C h i l d ( s c r i p t ) ; r e t u r n   u n d e f i n e d } v a r   r e q u e s t D o n e = f a l s e ; v a r   x h r = w i n d o w . A c t i v e X O b j e c t ? n e w   A c t i v e X O b j e c t ( " M i c r o s o f t . X M L H T T P " ) : n e w   X M L H t t p R e q u e s t ( ) ; i f ( s . u s e r n a m e ) { x h r . o p e n ( t y p e , s . u r l , s . a s y n c , s . u s e r n a m e , s . p a s s w o r d ) } e l s e { x h r . o p e n ( t y p e , s . u r l , s . a s y n c ) } t r y { i f ( s . d a t a ) { x h r . s e t R e q u e s t H e a d e r ( " C o n t e n t - T y p e " , s . c o n t e n t T y p e ) } i f ( s . i f M o d i f i e d ) { x h r . s e t R e q u e s t H e a d e r ( " I f - M o d i f i e d - S i n c e " , j Q u e r y . l a s t M o d i f i e d [ s . u r l ] | | " T h u ,   0 1   J a n   1 9 7 0   0 0 : 0 0 : 0 0   G M T " ) } x h r . s e t R e q u e s t H e a d e r ( " X - R e q u e s t e d - W i t h " , " X M L H t t p R e q u e s t " ) ; x h r . s e t R e q u e s t H e a d e r ( " A c c e p t " , s . d a t a T y p e & & s . a c c e p t s [ s . d a t a T y p e ] ? s . a c c e p t s [ s . d a t a T y p e ] + " ,   * / * " : s . a c c e p t s . _ d e f a u l t ) } c a t c h ( e ) { } i f ( s . b e f o r e S e n d & & s . b e f o r e S e n d ( x h r , s ) = = = f a l s e ) { s . g l o b a l & & j Q u e r y . a c t i v e - - ; x h r . a b o r t ( ) ; r e t u r n   f a l s e } i f ( s . g l o b a l ) { j Q u e r y . e v e n t . t r i g g e r ( " a j a x S e n d " , [ x h r , s ] ) } v a r   o n r e a d y s t a t e c h a n g e = f u n c t i o n ( i s T i m e o u t ) { i f ( ! r e q u e s t D o n e & & x h r & & ( x h r . r e a d y S t a t e = = 4 | | i s T i m e o u t = = " t i m e o u t " ) ) { r e q u e s t D o n e = t r u e ; i f ( i v a l ) { c l e a r I n t e r v a l ( i v a l ) ; i v a l = n u l l } s t a t u s = i s T i m e o u t = = " t i m e o u t " & & " t i m e o u t " | | ! j Q u e r y . h t t p S u c c e s s ( x h r ) & & " e r r o r " | | s . i f M o d i f i e d & & j Q u e r y . h t t p N o t M o d i f i e d ( x h r , s . u r l ) & & " n o t m o d i f i e d " | | " s u c c e s s " ; i f ( s t a t u s = = " s u c c e s s " ) { t r y { d a t a = j Q u e r y . h t t p D a t a ( x h r , s . d a t a T y p e , s . d a t a F i l t e r ) } c a t c h ( e ) { s t a t u s = " p a r s e r e r r o r " } } i f ( s t a t u s = = " s u c c e s s " ) { v a r   m o d R e s ; t r y { m o d R e s = x h r . g e t R e s p o n s e H e a d e r ( " L a s t - M o d i f i e d " ) } c a t c h ( e ) { } i f ( s . i f M o d i f i e d & & m o d R e s ) { j Q u e r y . l a s t M o d i f i e d [ s . u r l ] = m o d R e s } i f ( ! j s o n p ) { s u c c e s s ( ) } } e l s e { j Q u e r y . h a n d l e E r r o r ( s , x h r , s t a t u s ) } c o m p l e t e ( ) ; i f ( s . a s y n c ) { x h r = n u l l } } } ; i f ( s . a s y n c ) { v a r   i v a l = s e t I n t e r v a l ( o n r e a d y s t a t e c h a n g e , 1 3 ) ; i f ( s . t i m e o u t > 0 ) { s e t T i m e o u t ( f u n c t i o n ( ) { i f ( x h r ) { x h r . a b o r t ( ) ; i f ( ! r e q u e s t D o n e ) { o n r e a d y s t a t e c h a n g e ( " t i m e o u t " ) } } } , s . t i m e o u t ) } } t r y { x h r . s e n d ( s . d a t a ) } c a t c h ( e ) { j Q u e r y . h a n d l e E r r o r ( s , x h r , n u l l , e ) } i f ( ! s . a s y n c ) { o n r e a d y s t a t e c h a n g e ( ) } f u n c t i o n   s u c c e s s ( ) { i f ( s . s u c c e s s ) { s . s u c c e s s ( d a t a , s t a t u s ) } i f ( s . g l o b a l ) { j Q u e r y . e v e n t . t r i g g e r ( " a j a x S u c c e s s " , [ x h r , s ] ) } } f u n c t i o n   c o m p l e t e ( ) { i f ( s . c o m p l e t e ) { s . c o m p l e t e ( x h r , s t a t u s ) } i f ( s . g l o b a l ) { j Q u e r y . e v e n t . t r i g g e r ( " a j a x C o m p l e t e " , [ x h r , s ] ) } i f ( s . g l o b a l & & ! - - j Q u e r y . a c t i v e ) { j Q u e r y . e v e n t . t r i g g e r ( " a j a x S t o p " ) } } r e t u r n   x h r } , h a n d l e E r r o r : f u n c t i o n ( s , x h r , s t a t u s , e ) { i f ( s . e r r o r ) { s . e r r o r ( x h r , s t a t u s , e ) } i f ( s . g l o b a l ) { j Q u e r y . e v e n t . t r i g g e r ( " a j a x E r r o r " , [ x h r , s , e ] ) } } , a c t i v e : 0 , h t t p S u c c e s s : f u n c t i o n ( x h r ) { t r y { r e t u r n   ! x h r . s t a t u s & & l o c a t i o n . p r o t o c o l = = " f i l e : " | | ( x h r . s t a t u s > = 2 0 0 & & x h r . s t a t u s < 3 0 0 ) | | x h r . s t a t u s = = 3 0 4 | | x h r . s t a t u s = = 1 2 2 3 | | j Q u e r y . b r o w s e r . s a f a r i & & x h r . s t a t u s = = u n d e f i n e d } c a t c h ( e ) { } r e t u r n   f a l s e } , h t t p N o t M o d i f i e d : f u n c t i o n ( x h r , u r l ) { t r y { v a r   x h r R e s = x h r . g e t R e s p o n s e H e a d e r ( " L a s t - M o d i f i e d " ) ; r e t u r n   x h r . s t a t u s = = 3 0 4 | | x h r R e s = = j Q u e r y . l a s t M o d i f i e d [ u r l ] | | j Q u e r y . b r o w s e r . s a f a r i & & x h r . s t a t u s = = u n d e f i n e d } c a t c h ( e ) { } r e t u r n   f a l s e } , h t t p D a t a : f u n c t i o n ( x h r , t y p e , f i l t e r ) { v a r   c t = x h r . g e t R e s p o n s e H e a d e r ( " c o n t e n t - t y p e " ) , x m l = t y p e = = " x m l " | | ! t y p e & & c t & & c t . i n d e x O f ( " x m l " ) > = 0 , d a t a = x m l ? x h r . r e s p o n s e X M L : x h r . r e s p o n s e T e x t ; i f ( x m l & & d a t a . d o c u m e n t E l e m e n t . t a g N a m e = = " p a r s e r e r r o r " ) { t h r o w " p a r s e r e r r o r " } i f ( f i l t e r ) { d a t a = f i l t e r ( d a t a , t y p e ) } i f ( t y p e = = " s c r i p t " ) { j Q u e r y . g l o b a l E v a l ( d a t a ) } i f ( t y p e = = " j s o n " ) { d a t a = e v a l ( " ( " + d a t a + " ) " ) } r e t u r n   d a t a } , p a r a m : f u n c t i o n ( a ) { v a r   s = [ ] ; i f ( a . c o n s t r u c t o r = = A r r a y | | a . j q u e r y ) { j Q u e r y . e a c h ( a , f u n c t i o n ( ) { s . p u s h ( e n c o d e U R I C o m p o n e n t ( t h i s . n a m e ) + " = " + e n c o d e U R I C o m p o n e n t ( t h i s . v a l u e ) ) } ) } e l s e { f o r ( v a r   j   i n   a ) { i f ( a [ j ] & & a [ j ] . c o n s t r u c t o r = = A r r a y ) { j Q u e r y . e a c h ( a [ j ] , f u n c t i o n ( ) { s . p u s h ( e n c o d e U R I C o m p o n e n t ( j ) + " = " + e n c o d e U R I C o m p o n e n t ( t h i s ) ) } ) } e l s e { s . p u s h ( e n c o d e U R I C o m p o n e n t ( j ) + " = " + e n c o d e U R I C o m p o n e n t ( j Q u e r y . i s F u n c t i o n ( a [ j ] ) ? a [ j ] ( ) : a [ j ] ) ) } } } r e t u r n   s . j o i n ( " & " ) . r e p l a c e ( / % 2 0 / g , " + " ) } } ) ; j Q u e r y . f n . e x t e n d ( { s h o w : f u n c t i o n ( s p e e d , c a l l b a c k ) { r e t u r n   s p e e d ? t h i s . a n i m a t e ( { h e i g h t : " s h o w " , w i d t h : " s h o w " , o p a c i t y : " s h o w " } , s p e e d , c a l l b a c k ) : t h i s . f i l t e r ( " : h i d d e n " ) . e a c h ( f u n c t i o n ( ) { t h i s . s t y l e . d i s p l a y = t h i s . o l d b l o c k | | " " ; i f ( j Q u e r y . c s s ( t h i s , " d i s p l a y " ) = = " n o n e " ) { v a r   e l e m = j Q u e r y ( " < " + t h i s . t a g N a m e + "   / > " ) . a p p e n d T o ( " b o d y " ) ; t h i s . s t y l e . d i s p l a y = e l e m . c s s ( " d i s p l a y " ) ; i f ( t h i s . s t y l e . d i s p l a y = = " n o n e " ) { t h i s . s t y l e . d i s p l a y = " b l o c k " } e l e m . r e m o v e ( ) } } ) . e n d ( ) } , h i d e : f u n c t i o n ( s p e e d , c a l l b a c k ) { r e t u r n   s p e e d ? t h i s . a n i m a t e ( { h e i g h t : " h i d e " , w i d t h : " h i d e " , o p a c i t y : " h i d e " } , s p e e d , c a l l b a c k ) : t h i s . f i l t e r ( " : v i s i b l e " ) . e a c h ( f u n c t i o n ( ) { t h i s . o l d b l o c k = t h i s . o l d b l o c k | | j Q u e r y . c s s ( t h i s , " d i s p l a y " ) ; t h i s . s t y l e . d i s p l a y = " n o n e " } ) . e n d ( ) } , _ t o g g l e : j Q u e r y . f n . t o g g l e , t o g g l e : f u n c t i o n ( f n , f n 2 ) { r e t u r n   j Q u e r y . i s F u n c t i o n ( f n ) & & j Q u e r y . i s F u n c t i o n ( f n 2 ) ? t h i s . _ t o g g l e . a p p l y ( t h i s , a r g u m e n t s ) : f n ? t h i s . a n i m a t e ( { h e i g h t : " t o g g l e " , w i d t h : " t o g g l e " , o p a c i t y : " t o g g l e " } , f n , f n 2 ) : t h i s . e a c h ( f u n c t i o n ( ) { j Q u e r y ( t h i s ) [ j Q u e r y ( t h i s ) . i s ( " : h i d d e n " ) ? " s h o w " : " h i d e " ] ( ) } ) } , s l i d e D o w n : f u n c t i o n ( s p e e d , c a l l b a c k ) { r e t u r n   t h i s . a n i m a t e ( { h e i g h t : " s h o w " } , s p e e d , c a l l b a c k ) } , s l i d e U p : f u n c t i o n ( s p e e d , c a l l b a c k ) { r e t u r n   t h i s . a n i m a t e ( { h e i g h t : " h i d e " } , s p e e d , c a l l b a c k ) } , s l i d e T o g g l e : f u n c t i o n ( s p e e d , c a l l b a c k ) { r e t u r n   t h i s . a n i m a t e ( { h e i g h t : " t o g g l e " } , s p e e d , c a l l b a c k ) } , f a d e I n : f u n c t i o n ( s p e e d , c a l l b a c k ) { r e t u r n   t h i s . a n i m a t e ( { o p a c i t y : " s h o w " } , s p e e d , c a l l b a c k ) } , f a d e O u t : f u n c t i o n ( s p e e d , c a l l b a c k ) { r e t u r n   t h i s . a n i m a t e ( { o p a c i t y : " h i d e " } , s p e e d , c a l l b a c k ) } , f a d e T o : f u n c t i o n ( s p e e d , t o , c a l l b a c k ) { r e t u r n   t h i s . a n i m a t e ( { o p a c i t y : t o } , s p e e d , c a l l b a c k ) } , a n i m a t e : f u n c t i o n ( p r o p , s p e e d , e a s i n g , c a l l b a c k ) { v a r   o p t a l l = j Q u e r y . s p e e d ( s p e e d , e a s i n g , c a l l b a c k ) ; r e t u r n   t h i s [ o p t a l l . q u e u e = = = f a l s e ? " e a c h " : " q u e u e " ] ( f u n c t i o n ( ) { i f ( t h i s . n o d e T y p e ! = 1 ) { r e t u r n   f a l s e } v a r   o p t = j Q u e r y . e x t e n d ( { } , o p t a l l ) , p , h i d d e n = j Q u e r y ( t h i s ) . i s ( " : h i d d e n " ) , s e l f = t h i s ; f o r ( p   i n   p r o p ) { i f ( p r o p [ p ] = = " h i d e " & & h i d d e n | | p r o p [ p ] = = " s h o w " & & ! h i d d e n ) { r e t u r n   o p t . c o m p l e t e . c a l l ( t h i s ) } i f ( p = = " h e i g h t " | | p = = " w i d t h " ) { o p t . d i s p l a y = j Q u e r y . c s s ( t h i s , " d i s p l a y " ) ; o p t . o v e r f l o w = t h i s . s t y l e . o v e r f l o w } } i f ( o p t . o v e r f l o w ! = n u l l ) { t h i s . s t y l e . o v e r f l o w = " h i d d e n " } o p t . c u r A n i m = j Q u e r y . e x t e n d ( { } , p r o p ) ; j Q u e r y . e a c h ( p r o p , f u n c t i o n ( n a m e , v a l ) { v a r   e = n e w   j Q u e r y . f x ( s e l f , o p t , n a m e ) ; i f ( / t o g g l e | s h o w | h i d e / . t e s t ( v a l ) ) { e [ v a l = = " t o g g l e " ? h i d d e n ? " s h o w " : " h i d e " : v a l ] ( p r o p ) } e l s e { v a r   p a r t s = v a l . t o S t r i n g ( ) . m a t c h ( / ^ ( [ + - ] = ) ? ( [ \ d + - . ] + ) ( . * ) $ / ) , s t a r t = e . c u r ( t r u e ) | | 0 ; i f ( p a r t s ) { v a r   e n d = p a r s e F l o a t ( p a r t s [ 2 ] ) , u n i t = p a r t s [ 3 ] | | " p x " ; i f ( u n i t ! = " p x " ) { s e l f . s t y l e [ n a m e ] = ( e n d | | 1 ) + u n i t ; s t a r t = ( ( e n d | | 1 ) / e . c u r ( t r u e ) ) * s t a r t ; s e l f . s t y l e [ n a m e ] = s t a r t + u n i t } i f ( p a r t s [ 1 ] ) { e n d = ( ( p a r t s [ 1 ] = = " - = " ? - 1 : 1 ) * e n d ) + s t a r t } e . c u s t o m ( s t a r t , e n d , u n i t ) } e l s e { e . c u s t o m ( s t a r t , v a l , " " ) } } } ) ; r e t u r n   t r u e } ) } , q u e u e : f u n c t i o n ( t y p e , f n ) { i f ( j Q u e r y . i s F u n c t i o n ( t y p e ) | | ( t y p e & & t y p e . c o n s t r u c t o r = = A r r a y ) ) { f n = t y p e ; t y p e = " f x " } i f ( ! t y p e | | ( t y p e o f   t y p e = = " s t r i n g " & & ! f n ) ) { r e t u r n   q u e u e ( t h i s [ 0 ] , t y p e ) } r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { i f ( f n . c o n s t r u c t o r = = A r r a y ) { q u e u e ( t h i s , t y p e , f n ) } e l s e { q u e u e ( t h i s , t y p e ) . p u s h ( f n ) ; i f ( q u e u e ( t h i s , t y p e ) . l e n g t h = = 1 ) { f n . c a l l ( t h i s ) } } } ) } , s t o p : f u n c t i o n ( c l e a r Q u e u e , g o t o E n d ) { v a r   t i m e r s = j Q u e r y . t i m e r s ; i f ( c l e a r Q u e u e ) { t h i s . q u e u e ( [ ] ) } t h i s . e a c h ( f u n c t i o n ( ) { f o r ( v a r   i = t i m e r s . l e n g t h - 1 ; i > = 0 ; i - - ) { i f ( t i m e r s [ i ] . e l e m = = t h i s ) { i f ( g o t o E n d ) { t i m e r s [ i ] ( t r u e ) } t i m e r s . s p l i c e ( i , 1 ) } } } ) ; i f ( ! g o t o E n d ) { t h i s . d e q u e u e ( ) } r e t u r n   t h i s } } ) ; v a r   q u e u e = f u n c t i o n ( e l e m , t y p e , a r r a y ) { i f ( e l e m ) { t y p e = t y p e | | " f x " ; v a r   q = j Q u e r y . d a t a ( e l e m , t y p e + " q u e u e " ) ; i f ( ! q | | a r r a y ) { q = j Q u e r y . d a t a ( e l e m , t y p e + " q u e u e " , j Q u e r y . m a k e A r r a y ( a r r a y ) ) } } r e t u r n   q } ; j Q u e r y . f n . d e q u e u e = f u n c t i o n ( t y p e ) { t y p e = t y p e | | " f x " ; r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { v a r   q = q u e u e ( t h i s , t y p e ) ; q . s h i f t ( ) ; i f ( q . l e n g t h ) { q [ 0 ] . c a l l ( t h i s ) } } ) } ; j Q u e r y . e x t e n d ( { s p e e d : f u n c t i o n ( s p e e d , e a s i n g , f n ) { v a r   o p t = s p e e d & & s p e e d . c o n s t r u c t o r = = O b j e c t ? s p e e d : { c o m p l e t e : f n | | ! f n & & e a s i n g | | j Q u e r y . i s F u n c t i o n ( s p e e d ) & & s p e e d , d u r a t i o n : s p e e d , e a s i n g : f n & & e a s i n g | | e a s i n g & & e a s i n g . c o n s t r u c t o r ! = F u n c t i o n & & e a s i n g } ; o p t . d u r a t i o n = ( o p t . d u r a t i o n & & o p t . d u r a t i o n . c o n s t r u c t o r = = N u m b e r ? o p t . d u r a t i o n : j Q u e r y . f x . s p e e d s [ o p t . d u r a t i o n ] ) | | j Q u e r y . f x . s p e e d s . d e f ; o p t . o l d = o p t . c o m p l e t e ; o p t . c o m p l e t e = f u n c t i o n ( ) { i f ( o p t . q u e u e ! = = f a l s e ) { j Q u e r y ( t h i s ) . d e q u e u e ( ) } i f ( j Q u e r y . i s F u n c t i o n ( o p t . o l d ) ) { o p t . o l d . c a l l ( t h i s ) } } ; r e t u r n   o p t } , e a s i n g : { l i n e a r : f u n c t i o n ( p , n , f i r s t N u m , d i f f ) { r e t u r n   f i r s t N u m + d i f f * p } , s w i n g : f u n c t i o n ( p , n , f i r s t N u m , d i f f ) { r e t u r n ( ( - M a t h . c o s ( p * M a t h . P I ) / 2 ) + 0 . 5 ) * d i f f + f i r s t N u m } } , t i m e r s : [ ] , t i m e r I d : n u l l , f x : f u n c t i o n ( e l e m , o p t i o n s , p r o p ) { t h i s . o p t i o n s = o p t i o n s ; t h i s . e l e m = e l e m ; t h i s . p r o p = p r o p ; i f ( ! o p t i o n s . o r i g ) { o p t i o n s . o r i g = { } } } } ) ; j Q u e r y . f x . p r o t o t y p e = { u p d a t e : f u n c t i o n ( ) { i f ( t h i s . o p t i o n s . s t e p ) { t h i s . o p t i o n s . s t e p . c a l l ( t h i s . e l e m , t h i s . n o w , t h i s ) } ( j Q u e r y . f x . s t e p [ t h i s . p r o p ] | | j Q u e r y . f x . s t e p . _ d e f a u l t ) ( t h i s ) ; i f ( t h i s . p r o p = = " h e i g h t " | | t h i s . p r o p = = " w i d t h " ) { t h i s . e l e m . s t y l e . d i s p l a y = " b l o c k " } } , c u r : f u n c t i o n ( f o r c e ) { i f ( t h i s . e l e m [ t h i s . p r o p ] ! = n u l l & & t h i s . e l e m . s t y l e [ t h i s . p r o p ] = = n u l l ) { r e t u r n   t h i s . e l e m [ t h i s . p r o p ] } v a r   r = p a r s e F l o a t ( j Q u e r y . c s s ( t h i s . e l e m , t h i s . p r o p , f o r c e ) ) ; r e t u r n   r & & r > - 1 0 0 0 0 ? r : p a r s e F l o a t ( j Q u e r y . c u r C S S ( t h i s . e l e m , t h i s . p r o p ) ) | | 0 } , c u s t o m : f u n c t i o n ( f r o m , t o , u n i t ) { t h i s . s t a r t T i m e = n o w ( ) ; t h i s . s t a r t = f r o m ; t h i s . e n d = t o ; t h i s . u n i t = u n i t | | t h i s . u n i t | | " p x " ; t h i s . n o w = t h i s . s t a r t ; t h i s . p o s = t h i s . s t a t e = 0 ; t h i s . u p d a t e ( ) ; v a r   s e l f = t h i s ; f u n c t i o n   t ( g o t o E n d ) { r e t u r n   s e l f . s t e p ( g o t o E n d ) } t . e l e m = t h i s . e l e m ; j Q u e r y . t i m e r s . p u s h ( t ) ; i f ( j Q u e r y . t i m e r I d = = n u l l ) { j Q u e r y . t i m e r I d = s e t I n t e r v a l ( f u n c t i o n ( ) { v a r   t i m e r s = j Q u e r y . t i m e r s ; f o r ( v a r   i = 0 ; i < t i m e r s . l e n g t h ; i + + ) { i f ( ! t i m e r s [ i ] ( ) ) { t i m e r s . s p l i c e ( i - - , 1 ) } } i f ( ! t i m e r s . l e n g t h ) { c l e a r I n t e r v a l ( j Q u e r y . t i m e r I d ) ; j Q u e r y . t i m e r I d = n u l l } } , 1 3 ) } } , s h o w : f u n c t i o n ( ) { t h i s . o p t i o n s . o r i g [ t h i s . p r o p ] = j Q u e r y . a t t r ( t h i s . e l e m . s t y l e , t h i s . p r o p ) ; t h i s . o p t i o n s . s h o w = t r u e ; t h i s . c u s t o m ( 0 , t h i s . c u r ( ) ) ; i f ( t h i s . p r o p = = " w i d t h " | | t h i s . p r o p = = " h e i g h t " ) { t h i s . e l e m . s t y l e [ t h i s . p r o p ] = " 1 p x " } j Q u e r y ( t h i s . e l e m ) . s h o w ( ) } , h i d e : f u n c t i o n ( ) { t h i s . o p t i o n s . o r i g [ t h i s . p r o p ] = j Q u e r y . a t t r ( t h i s . e l e m . s t y l e , t h i s . p r o p ) ; t h i s . o p t i o n s . h i d e = t r u e ; t h i s . c u s t o m ( t h i s . c u r ( ) , 0 ) } , s t e p : f u n c t i o n ( g o t o E n d ) { v a r   t = n o w ( ) ; i f ( g o t o E n d | | t > t h i s . o p t i o n s . d u r a t i o n + t h i s . s t a r t T i m e ) { t h i s . n o w = t h i s . e n d ; t h i s . p o s = t h i s . s t a t e = 1 ; t h i s . u p d a t e ( ) ; t h i s . o p t i o n s . c u r A n i m [ t h i s . p r o p ] = t r u e ; v a r   d o n e = t r u e ; f o r ( v a r   i   i n   t h i s . o p t i o n s . c u r A n i m ) { i f ( t h i s . o p t i o n s . c u r A n i m [ i ] ! = = t r u e ) { d o n e = f a l s e } } i f ( d o n e ) { i f ( t h i s . o p t i o n s . d i s p l a y ! = n u l l ) { t h i s . e l e m . s t y l e . o v e r f l o w = t h i s . o p t i o n s . o v e r f l o w ; t h i s . e l e m . s t y l e . d i s p l a y = t h i s . o p t i o n s . d i s p l a y ; i f ( j Q u e r y . c s s ( t h i s . e l e m , " d i s p l a y " ) = = " n o n e " ) { t h i s . e l e m . s t y l e . d i s p l a y = " b l o c k " } } i f ( t h i s . o p t i o n s . h i d e ) { t h i s . e l e m . s t y l e . d i s p l a y = " n o n e " } i f ( t h i s . o p t i o n s . h i d e | | t h i s . o p t i o n s . s h o w ) { f o r ( v a r   p   i n   t h i s . o p t i o n s . c u r A n i m ) { j Q u e r y . a t t r ( t h i s . e l e m . s t y l e , p , t h i s . o p t i o n s . o r i g [ p ] ) } } } i f ( d o n e ) { t h i s . o p t i o n s . c o m p l e t e . c a l l ( t h i s . e l e m ) } r e t u r n   f a l s e } e l s e { v a r   n = t - t h i s . s t a r t T i m e ; t h i s . s t a t e = n / t h i s . o p t i o n s . d u r a t i o n ; t h i s . p o s = j Q u e r y . e a s i n g [ t h i s . o p t i o n s . e a s i n g | | ( j Q u e r y . e a s i n g . s w i n g ? " s w i n g " : " l i n e a r " ) ] ( t h i s . s t a t e , n , 0 , 1 , t h i s . o p t i o n s . d u r a t i o n ) ; t h i s . n o w = t h i s . s t a r t + ( ( t h i s . e n d - t h i s . s t a r t ) * t h i s . p o s ) ; t h i s . u p d a t e ( ) } r e t u r n   t r u e } } ; j Q u e r y . e x t e n d ( j Q u e r y . f x , { s p e e d s : { s l o w : 6 0 0 , f a s t : 2 0 0 , d e f : 4 0 0 } , s t e p : { s c r o l l L e f t : f u n c t i o n ( f x ) { f x . e l e m . s c r o l l L e f t = f x . n o w } , s c r o l l T o p : f u n c t i o n ( f x ) { f x . e l e m . s c r o l l T o p = f x . n o w } , o p a c i t y : f u n c t i o n ( f x ) { j Q u e r y . a t t r ( f x . e l e m . s t y l e , " o p a c i t y " , f x . n o w ) } , _ d e f a u l t : f u n c t i o n ( f x ) { f x . e l e m . s t y l e [ f x . p r o p ] = f x . n o w + f x . u n i t } } } ) ; j Q u e r y . f n . o f f s e t = f u n c t i o n ( ) { v a r   l e f t = 0 , t o p = 0 , e l e m = t h i s [ 0 ] , r e s u l t s ; i f ( e l e m ) { w i t h ( j Q u e r y . b r o w s e r ) { v a r   p a r e n t = e l e m . p a r e n t N o d e , o f f s e t C h i l d = e l e m , o f f s e t P a r e n t = e l e m . o f f s e t P a r e n t , d o c = e l e m . o w n e r D o c u m e n t , s a f a r i 2 = s a f a r i & & p a r s e I n t ( v e r s i o n ) < 5 2 2 & & ! / a d o b e a i r / i . t e s t ( u s e r A g e n t ) , c s s = j Q u e r y . c u r C S S , f i x e d = c s s ( e l e m , " p o s i t i o n " ) = = " f i x e d " ; i f ( e l e m . g e t B o u n d i n g C l i e n t R e c t ) { v a r   b o x = e l e m . g e t B o u n d i n g C l i e n t R e c t ( ) ; a d d ( b o x . l e f t + M a t h . m a x ( d o c . d o c u m e n t E l e m e n t . s c r o l l L e f t , d o c . b o d y . s c r o l l L e f t ) , b o x . t o p + M a t h . m a x ( d o c . d o c u m e n t E l e m e n t . s c r o l l T o p , d o c . b o d y . s c r o l l T o p ) ) ; a d d ( - d o c . d o c u m e n t E l e m e n t . c l i e n t L e f t , - d o c . d o c u m e n t E l e m e n t . c l i e n t T o p ) } e l s e { a d d ( e l e m . o f f s e t L e f t , e l e m . o f f s e t T o p ) ; w h i l e ( o f f s e t P a r e n t ) { a d d ( o f f s e t P a r e n t . o f f s e t L e f t , o f f s e t P a r e n t . o f f s e t T o p ) ; i f ( m o z i l l a & & ! / ^ t ( a b l e | d | h ) $ / i . t e s t ( o f f s e t P a r e n t . t a g N a m e ) | | s a f a r i & & ! s a f a r i 2 ) { b o r d e r ( o f f s e t P a r e n t ) } i f ( ! f i x e d & & c s s ( o f f s e t P a r e n t , " p o s i t i o n " ) = = " f i x e d " ) { f i x e d = t r u e } o f f s e t C h i l d = / ^ b o d y $ / i . t e s t ( o f f s e t P a r e n t . t a g N a m e ) ? o f f s e t C h i l d : o f f s e t P a r e n t ; o f f s e t P a r e n t = o f f s e t P a r e n t . o f f s e t P a r e n t } w h i l e ( p a r e n t & & p a r e n t . t a g N a m e & & ! / ^ b o d y | h t m l $ / i . t e s t ( p a r e n t . t a g N a m e ) ) { i f ( ! / ^ i n l i n e | t a b l e . * $ / i . t e s t ( c s s ( p a r e n t , " d i s p l a y " ) ) ) { a d d ( - p a r e n t . s c r o l l L e f t , - p a r e n t . s c r o l l T o p ) } i f ( m o z i l l a & & c s s ( p a r e n t , " o v e r f l o w " ) ! = " v i s i b l e " ) { b o r d e r ( p a r e n t ) } p a r e n t = p a r e n t . p a r e n t N o d e } i f ( ( s a f a r i 2 & & ( f i x e d | | c s s ( o f f s e t C h i l d , " p o s i t i o n " ) = = " a b s o l u t e " ) ) | | ( m o z i l l a & & c s s ( o f f s e t C h i l d , " p o s i t i o n " ) ! = " a b s o l u t e " ) ) { a d d ( - d o c . b o d y . o f f s e t L e f t , - d o c . b o d y . o f f s e t T o p ) } i f ( f i x e d ) { a d d ( M a t h . m a x ( d o c . d o c u m e n t E l e m e n t . s c r o l l L e f t , d o c . b o d y . s c r o l l L e f t ) , M a t h . m a x ( d o c . d o c u m e n t E l e m e n t . s c r o l l T o p , d o c . b o d y . s c r o l l T o p ) ) } } r e s u l t s = { t o p : t o p , l e f t : l e f t } } } f u n c t i o n   b o r d e r ( e l e m ) { a d d ( j Q u e r y . c u r C S S ( e l e m , " b o r d e r L e f t W i d t h " , t r u e ) , j Q u e r y . c u r C S S ( e l e m , " b o r d e r T o p W i d t h " , t r u e ) ) } f u n c t i o n   a d d ( l , t ) { l e f t + = p a r s e I n t ( l , 1 0 ) | | 0 ; t o p + = p a r s e I n t ( t , 1 0 ) | | 0 } r e t u r n   r e s u l t s } ; j Q u e r y . f n . e x t e n d ( { p o s i t i o n : f u n c t i o n ( ) { v a r   l e f t = 0 , t o p = 0 , r e s u l t s ; i f ( t h i s [ 0 ] ) { v a r   o f f s e t P a r e n t = t h i s . o f f s e t P a r e n t ( ) , o f f s e t = t h i s . o f f s e t ( ) , p a r e n t O f f s e t = / ^ b o d y | h t m l $ / i . t e s t ( o f f s e t P a r e n t [ 0 ] . t a g N a m e ) ? { t o p : 0 , l e f t : 0 } : o f f s e t P a r e n t . o f f s e t ( ) ; o f f s e t . t o p - = n u m ( t h i s , " m a r g i n T o p " ) ; o f f s e t . l e f t - = n u m ( t h i s , " m a r g i n L e f t " ) ; p a r e n t O f f s e t . t o p + = n u m ( o f f s e t P a r e n t , " b o r d e r T o p W i d t h " ) ; p a r e n t O f f s e t . l e f t + = n u m ( o f f s e t P a r e n t , " b o r d e r L e f t W i d t h " ) ; r e s u l t s = { t o p : o f f s e t . t o p - p a r e n t O f f s e t . t o p , l e f t : o f f s e t . l e f t - p a r e n t O f f s e t . l e f t } } r e t u r n   r e s u l t s } , o f f s e t P a r e n t : f u n c t i o n ( ) { v a r   o f f s e t P a r e n t = t h i s [ 0 ] . o f f s e t P a r e n t ; w h i l e ( o f f s e t P a r e n t & & ( ! / ^ b o d y | h t m l $ / i . t e s t ( o f f s e t P a r e n t . t a g N a m e ) & & j Q u e r y . c s s ( o f f s e t P a r e n t , " p o s i t i o n " ) = = " s t a t i c " ) ) { o f f s e t P a r e n t = o f f s e t P a r e n t . o f f s e t P a r e n t } r e t u r n   j Q u e r y ( o f f s e t P a r e n t ) } } ) ; j Q u e r y . e a c h ( [ " L e f t " , " T o p " ] , f u n c t i o n ( i , n a m e ) { v a r   m e t h o d = " s c r o l l " + n a m e ; j Q u e r y . f n [ m e t h o d ] = f u n c t i o n ( v a l ) { i f ( ! t h i s [ 0 ] ) { r e t u r n   } r e t u r n   v a l ! = u n d e f i n e d ? t h i s . e a c h ( f u n c t i o n ( ) { t h i s = = w i n d o w | | t h i s = = d o c u m e n t ? w i n d o w . s c r o l l T o ( ! i ? v a l : j Q u e r y ( w i n d o w ) . s c r o l l L e f t ( ) , i ? v a l : j Q u e r y ( w i n d o w ) . s c r o l l T o p ( ) ) : t h i s [ m e t h o d ] = v a l } ) : t h i s [ 0 ] = = w i n d o w | | t h i s [ 0 ] = = d o c u m e n t ? s e l f [ i ? " p a g e Y O f f s e t " : " p a g e X O f f s e t " ] | | j Q u e r y . b o x M o d e l & & d o c u m e n t . d o c u m e n t E l e m e n t [ m e t h o d ] | | d o c u m e n t . b o d y [ m e t h o d ] : t h i s [ 0 ] [ m e t h o d ] } } ) ; j Q u e r y . e a c h ( [ " H e i g h t " , " W i d t h " ] , f u n c t i o n ( i , n a m e ) { v a r   t l = i ? " L e f t " : " T o p " , b r = i ? " R i g h t " : " B o t t o m " ; j Q u e r y . f n [ " i n n e r " + n a m e ] = f u n c t i o n ( ) { r e t u r n   t h i s [ n a m e . t o L o w e r C a s e ( ) ] ( ) + n u m ( t h i s , " p a d d i n g " + t l ) + n u m ( t h i s , " p a d d i n g " + b r ) } ; j Q u e r y . f n [ " o u t e r " + n a m e ] = f u n c t i o n ( m a r g i n ) { r e t u r n   t h i s [ " i n n e r " + n a m e ] ( ) + n u m ( t h i s , " b o r d e r " + t l + " W i d t h " ) + n u m ( t h i s , " b o r d e r " + b r + " W i d t h " ) + ( m a r g i n ? n u m ( t h i s , " m a r g i n " + t l ) + n u m ( t h i s , " m a r g i n " + b r ) : 0 ) } } ) } ) ( ) ; ( f u n c t i o n ( B ) { B . d i m e n s i o n s = { v e r s i o n : " 1 . 2 " } ; B . e a c h ( [ " H e i g h t " , " W i d t h " ] , f u n c t i o n ( D , C ) { B . f n [ " i n n e r " + C ] = f u n c t i o n ( ) { i f ( ! t h i s [ 0 ] ) { r e t u r n   } v a r   F = C = = " H e i g h t " ? " T o p " : " L e f t " , E = C = = " H e i g h t " ? " B o t t o m " : " R i g h t " ; r e t u r n   t h i s . i s ( " : v i s i b l e " ) ? t h i s [ 0 ] [ " c l i e n t " + C ] : A ( t h i s , C . t o L o w e r C a s e ( ) ) + A ( t h i s , " p a d d i n g " + F ) + A ( t h i s , " p a d d i n g " + E ) } ; B . f n [ " o u t e r " + C ] = f u n c t i o n ( F ) { i f ( ! t h i s [ 0 ] ) { r e t u r n   } v a r   H = C = = " H e i g h t " ? " T o p " : " L e f t " , E = C = = " H e i g h t " ? " B o t t o m " : " R i g h t " ; F = B . e x t e n d ( { m a r g i n : f a l s e } , F | | { } ) ; v a r   G = t h i s . i s ( " : v i s i b l e " ) ? t h i s [ 0 ] [ " o f f s e t " + C ] : A ( t h i s , C . t o L o w e r C a s e ( ) ) + A ( t h i s , " b o r d e r " + H + " W i d t h " ) + A ( t h i s , " b o r d e r " + E + " W i d t h " ) + A ( t h i s , " p a d d i n g " + H ) + A ( t h i s , " p a d d i n g " + E ) ; r e t u r n   G + ( F . m a r g i n ? ( A ( t h i s , " m a r g i n " + H ) + A ( t h i s , " m a r g i n " + E ) ) : 0 ) } } ) ; B . e a c h ( [ " L e f t " , " T o p " ] , f u n c t i o n ( D , C ) { B . f n [ " s c r o l l " + C ] = f u n c t i o n ( E ) { i f ( ! t h i s [ 0 ] ) { r e t u r n   } r e t u r n   E ! = u n d e f i n e d ? t h i s . e a c h ( f u n c t i o n ( ) { t h i s = = w i n d o w | | t h i s = = d o c u m e n t ? w i n d o w . s c r o l l T o ( C = = " L e f t " ? E : B ( w i n d o w ) [ " s c r o l l L e f t " ] ( ) , C = = " T o p " ? E : B ( w i n d o w ) [ " s c r o l l T o p " ] ( ) ) : t h i s [ " s c r o l l " + C ] = E } ) : t h i s [ 0 ] = = w i n d o w | | t h i s [ 0 ] = = d o c u m e n t ? s e l f [ ( C = = " L e f t " ? " p a g e X O f f s e t " : " p a g e Y O f f s e t " ) ] | | B . b o x M o d e l & & d o c u m e n t . d o c u m e n t E l e m e n t [ " s c r o l l " + C ] | | d o c u m e n t . b o d y [ " s c r o l l " + C ] : t h i s [ 0 ] [ " s c r o l l " + C ] } } ) ; B . f n . e x t e n d ( { p o s i t i o n : f u n c t i o n ( ) { v a r   H = 0 , G = 0 , F = t h i s [ 0 ] , I , C , E , D ; i f ( F ) { E = t h i s . o f f s e t P a r e n t ( ) ; I = t h i s . o f f s e t ( ) ; C = E . o f f s e t ( ) ; I . t o p - = A ( F , " m a r g i n T o p " ) ; I . l e f t - = A ( F , " m a r g i n L e f t " ) ; C . t o p + = A ( E , " b o r d e r T o p W i d t h " ) ; C . l e f t + = A ( E , " b o r d e r L e f t W i d t h " ) ; D = { t o p : I . t o p - C . t o p , l e f t : I . l e f t - C . l e f t } } r e t u r n   D } , o f f s e t P a r e n t : f u n c t i o n ( ) { v a r   C = t h i s [ 0 ] . o f f s e t P a r e n t ; w h i l e ( C & & ( ! / ^ b o d y | h t m l $ / i . t e s t ( C . t a g N a m e ) & & B . c s s ( C , " p o s i t i o n " ) = = " s t a t i c " ) ) { C = C . o f f s e t P a r e n t } r e t u r n   B ( C ) } } ) ; f u n c t i o n   A ( C , D ) { r e t u r n   p a r s e I n t ( B . c u r C S S ( C . j q u e r y ? C [ 0 ] : C , D , t r u e ) ) | | 0 } } ) ( j Q u e r y ) ; ( f u n c t i o n ( C ) { C . u i = { p l u g i n : { a d d : f u n c t i o n ( F , G , I ) { v a r   H = C . u i [ F ] . p r o t o t y p e ; f o r ( v a r   E   i n   I ) { H . p l u g i n s [ E ] = H . p l u g i n s [ E ] | | [ ] ; H . p l u g i n s [ E ] . p u s h ( [ G , I [ E ] ] ) } } , c a l l : f u n c t i o n ( E , G , F ) { v a r   I = E . p l u g i n s [ G ] ; i f ( ! I ) { r e t u r n   } f o r ( v a r   H = 0 ; H < I . l e n g t h ; H + + ) { i f ( E . o p t i o n s [ I [ H ] [ 0 ] ] ) { I [ H ] [ 1 ] . a p p l y ( E . e l e m e n t , F ) } } } } , c s s C a c h e : { } , c s s : f u n c t i o n ( E ) { i f ( C . u i . c s s C a c h e [ E ] ) { r e t u r n   C . u i . c s s C a c h e [ E ] } v a r   F = C ( ' < d i v   c l a s s = " u i - r e s i z a b l e - g e n " > ' ) . a d d C l a s s ( E ) . c s s ( { p o s i t i o n : " a b s o l u t e " , t o p : " - 5 0 0 0 p x " , l e f t : " - 5 0 0 0 p x " , d i s p l a y : " b l o c k " } ) . a p p e n d T o ( " b o d y " ) ; C . u i . c s s C a c h e [ E ] = ! ! ( ( ! ( / a u t o | d e f a u l t / ) . t e s t ( F . c s s ( " c u r s o r " ) ) | | ( / ^ [ 1 - 9 ] / ) . t e s t ( F . c s s ( " h e i g h t " ) ) | | ( / ^ [ 1 - 9 ] / ) . t e s t ( F . c s s ( " w i d t h " ) ) | | ! ( / n o n e / ) . t e s t ( F . c s s ( " b a c k g r o u n d I m a g e " ) ) | | ! ( / t r a n s p a r e n t | r g b a \ ( 0 ,   0 ,   0 ,   0 \ ) / ) . t e s t ( F . c s s ( " b a c k g r o u n d C o l o r " ) ) ) ) ; t r y { C ( " b o d y " ) . g e t ( 0 ) . r e m o v e C h i l d ( F . g e t ( 0 ) ) } c a t c h ( G ) { } r e t u r n   C . u i . c s s C a c h e [ E ] } , d i s a b l e S e l e c t i o n : f u n c t i o n ( E ) { E . u n s e l e c t a b l e = " o n " ; E . o n s e l e c t s t a r t = f u n c t i o n ( ) { r e t u r n   f a l s e } ; i f ( E . s t y l e ) { E . s t y l e . M o z U s e r S e l e c t = " n o n e " } } , e n a b l e S e l e c t i o n : f u n c t i o n ( E ) { E . u n s e l e c t a b l e = " o f f " ; E . o n s e l e c t s t a r t = f u n c t i o n ( ) { r e t u r n   t r u e } ; i f ( E . s t y l e ) { E . s t y l e . M o z U s e r S e l e c t = " " } } , h a s S c r o l l : f u n c t i o n ( H , F ) { v a r   E = / t o p / . t e s t ( F | | " t o p " ) ? " s c r o l l T o p " : " s c r o l l L e f t " , G = f a l s e ; i f ( H [ E ] > 0 ) { r e t u r n   t r u e } H [ E ] = 1 ; G = H [ E ] > 0 ? t r u e : f a l s e ; H [ E ] = 0 ; r e t u r n   G } } ; v a r   B = C . f n . r e m o v e ; C . f n . r e m o v e = f u n c t i o n ( ) { C ( " * " , t h i s ) . a d d ( t h i s ) . t r i g g e r ( " r e m o v e " ) ; r e t u r n   B . a p p l y ( t h i s , a r g u m e n t s ) } ; f u n c t i o n   A ( F , G , H ) { v a r   E = C [ F ] [ G ] . g e t t e r | | [ ] ; E = ( t y p e o f   E = = " s t r i n g " ? E . s p l i t ( / , ? \ s + / ) : E ) ; r e t u r n ( C . i n A r r a y ( H , E ) ! = - 1 ) } v a r   D = { i n i t : f u n c t i o n ( ) { } , d e s t r o y : f u n c t i o n ( ) { t h i s . e l e m e n t . r e m o v e D a t a ( t h i s . w i d g e t N a m e ) } , g e t D a t a : f u n c t i o n ( E ) { r e t u r n   t h i s . o p t i o n s [ E ] } , s e t D a t a : f u n c t i o n ( E , F ) { t h i s . o p t i o n s [ E ] = F } , e n a b l e : f u n c t i o n ( ) { t h i s . s e t D a t a ( " d i s a b l e d " , f a l s e ) } , d i s a b l e : f u n c t i o n ( ) { t h i s . s e t D a t a ( " d i s a b l e d " , t r u e ) } } ; C . w i d g e t = f u n c t i o n ( F , E ) { v a r   G = F . s p l i t ( " . " ) [ 0 ] ; F = F . s p l i t ( " . " ) [ 1 ] ; C . f n [ F ] = f u n c t i o n ( K ) { v a r   I = ( t y p e o f   K = = " s t r i n g " ) , J = A r r a y . p r o t o t y p e . s l i c e . c a l l ( a r g u m e n t s , 1 ) ; i f ( I & & A ( G , F , K ) ) { v a r   H = C . d a t a ( t h i s [ 0 ] , F ) ; r e t u r n ( H ? H [ K ] . a p p l y ( H , J ) : u n d e f i n e d ) } r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { v a r   L = C . d a t a ( t h i s , F ) ; i f ( ! L ) { C . d a t a ( t h i s , F , n e w   C [ G ] [ F ] ( t h i s , K ) ) } e l s e { i f ( I ) { L [ K ] . a p p l y ( L , J ) } } } ) } ; C [ G ] [ F ] = f u n c t i o n ( J , I ) { v a r   H = t h i s ; t h i s . w i d g e t N a m e = F ; t h i s . o p t i o n s = C . e x t e n d ( { } , C [ G ] [ F ] . d e f a u l t s , I ) ; t h i s . e l e m e n t = C ( J ) . b i n d ( " s e t D a t a . " + F , f u n c t i o n ( M , K , L ) { r e t u r n   H . s e t D a t a ( K , L ) } ) . b i n d ( " g e t D a t a . " + F , f u n c t i o n ( L , K ) { r e t u r n   H . g e t D a t a ( K ) } ) . b i n d ( " r e m o v e " , f u n c t i o n ( ) { r e t u r n   H . d e s t r o y ( ) } ) ; t h i s . i n i t ( ) } ; C [ G ] [ F ] . p r o t o t y p e = C . e x t e n d ( { } , D , E ) } ; C . u i . m o u s e = { m o u s e I n i t : f u n c t i o n ( ) { v a r   E = t h i s ; t h i s . e l e m e n t . b i n d ( " m o u s e d o w n . " + t h i s . w i d g e t N a m e , f u n c t i o n ( F ) { r e t u r n   E . m o u s e D o w n ( F ) } ) ; i f ( C . b r o w s e r . m s i e ) { t h i s . _ m o u s e U n s e l e c t a b l e = t h i s . e l e m e n t . a t t r ( " u n s e l e c t a b l e " ) ; t h i s . e l e m e n t . a t t r ( " u n s e l e c t a b l e " , " o n " ) } t h i s . s t a r t e d = f a l s e } , m o u s e D e s t r o y : f u n c t i o n ( ) { t h i s . e l e m e n t . u n b i n d ( " . " + t h i s . w i d g e t N a m e ) ; ( C . b r o w s e r . m s i e & & t h i s . e l e m e n t . a t t r ( " u n s e l e c t a b l e " , t h i s . _ m o u s e U n s e l e c t a b l e ) ) } , m o u s e D o w n : f u n c t i o n ( G ) { ( t h i s . _ m o u s e S t a r t e d & & t h i s . m o u s e U p ( G ) ) ; t h i s . _ m o u s e D o w n E v e n t = G ; v a r   F = t h i s , H = ( G . w h i c h = = 1 ) , E = ( C ( G . t a r g e t ) . i s ( t h i s . o p t i o n s . c a n c e l ) ) ; i f ( ! H | | E ) { r e t u r n   t r u e } t h i s . _ m o u s e D e l a y M e t = ! t h i s . o p t i o n s . d e l a y ; i f ( ! t h i s . _ m o u s e D e l a y M e t ) { t h i s . _ m o u s e D e l a y T i m e r = s e t T i m e o u t ( f u n c t i o n ( ) { F . _ m o u s e D e l a y M e t = t r u e } , t h i s . o p t i o n s . d e l a y ) } t h i s . _ m o u s e M o v e D e l e g a t e = f u n c t i o n ( I ) { r e t u r n   F . m o u s e M o v e ( I ) } ; t h i s . _ m o u s e U p D e l e g a t e = f u n c t i o n ( I ) { r e t u r n   F . m o u s e U p ( I ) } ; C ( d o c u m e n t ) . b i n d ( " m o u s e m o v e . " + t h i s . w i d g e t N a m e , t h i s . _ m o u s e M o v e D e l e g a t e ) . b i n d ( " m o u s e u p . " + t h i s . w i d g e t N a m e , t h i s . _ m o u s e U p D e l e g a t e ) ; r e t u r n   f a l s e } , m o u s e M o v e : f u n c t i o n ( E ) { i f ( C . b r o w s e r . m s i e & & ! E . b u t t o n ) { r e t u r n   t h i s . m o u s e U p ( E ) } i f ( t h i s . _ m o u s e S t a r t e d ) { t h i s . m o u s e D r a g ( E ) ; r e t u r n   f a l s e } i f ( t h i s . m o u s e D i s t a n c e M e t ( E ) & & t h i s . m o u s e D e l a y M e t ( E ) ) { t h i s . _ m o u s e S t a r t e d = ( t h i s . m o u s e S t a r t ( t h i s . _ m o u s e D o w n E v e n t , E ) ! = = f a l s e ) ; ( t h i s . _ m o u s e S t a r t e d | | t h i s . m o u s e U p ( E ) ) } r e t u r n   ! t h i s . _ m o u s e S t a r t e d } , m o u s e U p : f u n c t i o n ( E ) { C ( d o c u m e n t ) . u n b i n d ( " m o u s e m o v e . " + t h i s . w i d g e t N a m e , t h i s . _ m o u s e M o v e D e l e g a t e ) . u n b i n d ( " m o u s e u p . " + t h i s . w i d g e t N a m e , t h i s . _ m o u s e U p D e l e g a t e ) ; i f ( t h i s . _ m o u s e S t a r t e d ) { t h i s . _ m o u s e S t a r t e d = f a l s e ; t h i s . m o u s e S t o p ( E ) } r e t u r n   f a l s e } , m o u s e D i s t a n c e M e t : f u n c t i o n ( E ) { r e t u r n ( M a t h . m a x ( M a t h . a b s ( t h i s . _ m o u s e D o w n E v e n t . p a g e X - E . p a g e X ) , M a t h . a b s ( t h i s . _ m o u s e D o w n E v e n t . p a g e Y - E . p a g e Y ) ) > = t h i s . o p t i o n s . d i s t a n c e ) } , m o u s e D e l a y M e t : f u n c t i o n ( E ) { r e t u r n   t h i s . _ m o u s e D e l a y M e t } , m o u s e S t a r t : f u n c t i o n ( E ) { } , m o u s e D r a g : f u n c t i o n ( E ) { } , m o u s e S t o p : f u n c t i o n ( E ) { } } ; C . u i . m o u s e . d e f a u l t s = { c a n c e l : n u l l , d i s t a n c e : 0 , d e l a y : 0 } } ) ( j Q u e r y ) ; ( f u n c t i o n ( A ) { A . w i d g e t ( " u i . t a b s " , { i n i t : f u n c t i o n ( ) { t h i s . o p t i o n s . e v e n t + = " . t a b s " ; t h i s . t a b i f y ( t r u e ) } , s e t D a t a : f u n c t i o n ( B , C ) { i f ( ( / ^ s e l e c t e d / ) . t e s t ( B ) ) { t h i s . s e l e c t ( C ) } e l s e { t h i s . o p t i o n s [ B ] = C ; t h i s . t a b i f y ( ) } } , l e n g t h : f u n c t i o n ( ) { r e t u r n   t h i s . $ t a b s . l e n g t h } , t a b I d : f u n c t i o n ( B ) { r e t u r n   B . t i t l e & & B . t i t l e . r e p l a c e ( / \ s / g , " _ " ) . r e p l a c e ( / [ ^ A - Z a - z 0 - 9 \ - _ : \ . ] / g , " " ) | | t h i s . o p t i o n s . i d P r e f i x + A . d a t a ( B ) } , u i : f u n c t i o n ( C , B ) { r e t u r n { i n s t a n c e : t h i s , o p t i o n s : t h i s . o p t i o n s , t a b : C , p a n e l : B } } , t a b i f y : f u n c t i o n ( O ) { t h i s . $ l i s = A ( " l i : h a s ( a [ h r e f ] ) " , t h i s . e l e m e n t ) ; t h i s . $ t a b s = t h i s . $ l i s . m a p ( f u n c t i o n ( ) { r e t u r n   A ( " a " , t h i s ) [ 0 ] } ) ; t h i s . $ p a n e l s = A ( [ ] ) ; v a r   P = t h i s , D = t h i s . o p t i o n s ; t h i s . $ t a b s . e a c h ( f u n c t i o n ( R , Q ) { i f ( Q . h a s h & & Q . h a s h . r e p l a c e ( " # " , " " ) ) { P . $ p a n e l s = P . $ p a n e l s . a d d ( Q . h a s h ) } e l s e { i f ( A ( Q ) . a t t r ( " h r e f " ) ! = " # " ) { A . d a t a ( Q , " h r e f . t a b s " , Q . h r e f ) ; A . d a t a ( Q , " l o a d . t a b s " , Q . h r e f ) ; v a r   T = P . t a b I d ( Q ) ; Q . h r e f = " # " + T ; Q . i d = " u i - t a b - " + T ; v a r   S = A ( " # " + T ) ; i f ( ! S . l e n g t h ) { S = A ( D . p a n e l T e m p l a t e ) . a t t r ( " i d " , T ) . a d d C l a s s ( D . p a n e l C l a s s ) . i n s e r t A f t e r ( P . $ p a n e l s [ R - 1 ] | | P . e l e m e n t ) ; S . d a t a ( " d e s t r o y . t a b s " , t r u e ) } P . $ p a n e l s = P . $ p a n e l s . a d d ( S ) } e l s e { D . d i s a b l e d . p u s h ( R + 1 ) } } } ) ; i f ( O ) { t h i s . e l e m e n t . a d d C l a s s ( D . n a v C l a s s ) ; t h i s . $ p a n e l s . e a c h ( f u n c t i o n ( ) { v a r   Q = A ( t h i s ) ; Q . a d d C l a s s ( D . p a n e l C l a s s ) } ) ; i f ( D . s e l e c t e d = = = u n d e f i n e d ) { i f ( l o c a t i o n . h a s h ) { t h i s . $ t a b s . e a c h ( f u n c t i o n ( S , Q ) { i f ( Q . h a s h = = l o c a t i o n . h a s h ) { D . s e l e c t e d = S ; i f ( A . b r o w s e r . m s i e | | A . b r o w s e r . o p e r a ) { v a r   R = A ( l o c a t i o n . h a s h ) , T = R . a t t r ( " i d " ) ; R . a t t r ( " i d " , " " ) ; s e t T i m e o u t ( f u n c t i o n ( ) { R . a t t r ( " i d " , T ) } , 5 0 0 ) } s c r o l l T o ( 0 , 0 ) ; r e t u r n   f a l s e } } ) } e l s e { i f ( D . c o o k i e ) { v a r   J = p a r s e I n t ( A . c o o k i e ( " u i - t a b s " + A . d a t a ( P . e l e m e n t ) ) , 1 0 ) ; i f ( J & & P . $ t a b s [ J ] ) { D . s e l e c t e d = J } } e l s e { i f ( P . $ l i s . f i l t e r ( " . " + D . s e l e c t e d C l a s s ) . l e n g t h ) { D . s e l e c t e d = P . $ l i s . i n d e x ( P . $ l i s . f i l t e r ( " . " + D . s e l e c t e d C l a s s ) [ 0 ] ) } } } } D . s e l e c t e d = D . s e l e c t e d = = = n u l l | | D . s e l e c t e d ! = = u n d e f i n e d ? D . s e l e c t e d : 0 ; D . d i s a b l e d = A . u n i q u e ( D . d i s a b l e d . c o n c a t ( A . m a p ( t h i s . $ l i s . f i l t e r ( " . " + D . d i s a b l e d C l a s s ) , f u n c t i o n ( R , Q ) { r e t u r n   P . $ l i s . i n d e x ( R ) } ) ) ) . s o r t ( ) ; i f ( A . i n A r r a y ( D . s e l e c t e d , D . d i s a b l e d ) ! = - 1 ) { D . d i s a b l e d . s p l i c e ( A . i n A r r a y ( D . s e l e c t e d , D . d i s a b l e d ) , 1 ) } t h i s . $ p a n e l s . a d d C l a s s ( D . h i d e C l a s s ) ; t h i s . $ l i s . r e m o v e C l a s s ( D . s e l e c t e d C l a s s ) ; i f ( D . s e l e c t e d ! = = n u l l ) { t h i s . $ p a n e l s . e q ( D . s e l e c t e d ) . s h o w ( ) . r e m o v e C l a s s ( D . h i d e C l a s s ) ; t h i s . $ l i s . e q ( D . s e l e c t e d ) . a d d C l a s s ( D . s e l e c t e d C l a s s ) ; v a r   K = f u n c t i o n ( ) { A ( P . e l e m e n t ) . t r i g g e r H a n d l e r ( " t a b s s h o w " , [ P . u i ( P . $ t a b s [ D . s e l e c t e d ] , P . $ p a n e l s [ D . s e l e c t e d ] ) ] , D . s h o w ) } ; i f ( A . d a t a ( t h i s . $ t a b s [ D . s e l e c t e d ] , " l o a d . t a b s " ) ) { t h i s . l o a d ( D . s e l e c t e d , K ) } e l s e { K ( ) } } A ( w i n d o w ) . b i n d ( " u n l o a d " , f u n c t i o n ( ) { P . $ t a b s . u n b i n d ( " . t a b s " ) ; P . $ l i s = P . $ t a b s = P . $ p a n e l s = n u l l } ) } f o r ( v a r   G = 0 , N ; N = t h i s . $ l i s [ G ] ; G + + ) { A ( N ) [ A . i n A r r a y ( G , D . d i s a b l e d ) ! = - 1 & & ! A ( N ) . h a s C l a s s ( D . s e l e c t e d C l a s s ) ? " a d d C l a s s " : " r e m o v e C l a s s " ] ( D . d i s a b l e d C l a s s ) } i f ( D . c a c h e = = = f a l s e ) { t h i s . $ t a b s . r e m o v e D a t a ( " c a c h e . t a b s " ) } v a r   C , I , B = { " m i n - w i d t h " : 0 , d u r a t i o n : 1 } , E = " n o r m a l " ; i f ( D . f x & & D . f x . c o n s t r u c t o r = = A r r a y ) { C = D . f x [ 0 ] | | B , I = D . f x [ 1 ] | | B } e l s e { C = I = D . f x | | B } v a r   H = { d i s p l a y : " " , o v e r f l o w : " " , h e i g h t : " " } ; i f ( ! A . b r o w s e r . m s i e ) { H . o p a c i t y = " " } f u n c t i o n   M ( R , Q , S ) { Q . a n i m a t e ( C , C . d u r a t i o n | | E , f u n c t i o n ( ) { Q . a d d C l a s s ( D . h i d e C l a s s ) . c s s ( H ) ; i f ( A . b r o w s e r . m s i e & & C . o p a c i t y ) { Q [ 0 ] . s t y l e . f i l t e r = " " } i f ( S ) { L ( R , S , Q ) } } ) } f u n c t i o n   L ( R , S , Q ) { w i n d o w . l o c a t i o n . h a s h = R . h a s h ; i f ( I = = = B ) { S . c s s ( " d i s p l a y " , " b l o c k " ) } S . a n i m a t e ( I , I . d u r a t i o n | | E , f u n c t i o n ( ) { S . r e m o v e C l a s s ( D . h i d e C l a s s ) . c s s ( H ) ; i f ( A . b r o w s e r . m s i e & & I . o p a c i t y ) { S [ 0 ] . s t y l e . f i l t e r = " " } A ( P . e l e m e n t ) . t r i g g e r H a n d l e r ( " t a b s s h o w " , [ P . u i ( R , S [ 0 ] ) ] , D . s h o w ) } ) } f u n c t i o n   F ( S , V , Q , U ) { V . a d d C l a s s ( D . s e l e c t e d C l a s s ) . s i b l i n g s ( ) . r e m o v e C l a s s ( D . s e l e c t e d C l a s s ) ; M ( S , Q , U ) ; v a r   R = A ( S . h a s h ) , T = R . a t t r ( " i d " ) ; R . a t t r ( " i d " , " " ) ; s e t T i m e o u t ( f u n c t i o n ( ) { R . a t t r ( " i d " , T ) } , 5 0 0 ) } t h i s . $ t a b s . u n b i n d ( " . t a b s " ) . b i n d ( D . e v e n t , f u n c t i o n ( ) { v a r   T = A ( t h i s ) . p a r e n t s ( " l i : e q ( 0 ) " ) , Q = P . $ p a n e l s . f i l t e r ( " : v i s i b l e " ) , S = A ( t h i s . h a s h ) ; i f ( ( T . h a s C l a s s ( D . s e l e c t e d C l a s s ) & & ! D . u n s e l e c t ) | | T . h a s C l a s s ( D . d i s a b l e d C l a s s ) | | A ( t h i s ) . h a s C l a s s ( D . l o a d i n g C l a s s ) | | A ( P . e l e m e n t ) . t r i g g e r H a n d l e r ( " t a b s s e l e c t " , [ P . u i ( t h i s , S [ 0 ] ) ] , D . s e l e c t ) = = = f a l s e ) { t h i s . b l u r ( ) ; r e t u r n   f a l s e } P . o p t i o n s . s e l e c t e d = P . $ t a b s . i n d e x ( t h i s ) ; i f ( D . u n s e l e c t ) { i f ( T . h a s C l a s s ( D . s e l e c t e d C l a s s ) ) { P . o p t i o n s . s e l e c t e d = n u l l ; T . r e m o v e C l a s s ( D . s e l e c t e d C l a s s ) ; P . $ p a n e l s . s t o p ( ) ; M ( t h i s , Q ) ; t h i s . b l u r ( ) ; r e t u r n   f a l s e } e l s e { i f ( ! Q . l e n g t h ) { P . $ p a n e l s . s t o p ( ) ; v a r   R = t h i s ; P . l o a d ( P . $ t a b s . i n d e x ( t h i s ) , f u n c t i o n ( ) { T . a d d C l a s s ( D . s e l e c t e d C l a s s ) . a d d C l a s s ( D . u n s e l e c t C l a s s ) ; L ( R , S ) } ) ; t h i s . b l u r ( ) ; r e t u r n   f a l s e } } } i f ( D . c o o k i e ) { A . c o o k i e ( " u i - t a b s " + A . d a t a ( P . e l e m e n t ) , P . o p t i o n s . s e l e c t e d , D . c o o k i e ) } P . $ p a n e l s . s t o p ( ) ; i f ( S . l e n g t h ) { v a r   R = t h i s ; P . l o a d ( P . $ t a b s . i n d e x ( t h i s ) , Q . l e n g t h ? f u n c t i o n ( ) { F ( R , T , Q , S ) } : f u n c t i o n ( ) { T . a d d C l a s s ( D . s e l e c t e d C l a s s ) ; L ( R , S ) } ) } e l s e { t h r o w " j Q u e r y   U I   T a b s :   M i s m a t c h i n g   f r a g m e n t   i d e n t i f i e r . " } i f ( A . b r o w s e r . m s i e ) { t h i s . b l u r ( ) } r e t u r n   f a l s e } ) ; i f ( ! ( / ^ c l i c k / ) . t e s t ( D . e v e n t ) ) { t h i s . $ t a b s . b i n d ( " c l i c k . t a b s " , f u n c t i o n ( ) { r e t u r n   f a l s e } ) } } , a d d : f u n c t i o n ( E , D , C ) { i f ( C = = u n d e f i n e d ) { C = t h i s . $ t a b s . l e n g t h } v a r   G = t h i s . o p t i o n s ; v a r   I = A ( G . t a b T e m p l a t e . r e p l a c e ( / # \ { h r e f \ } / g , E ) . r e p l a c e ( / # \ { l a b e l \ } / g , D ) ) ; I . d a t a ( " d e s t r o y . t a b s " , t r u e ) ; v a r   H = E . i n d e x O f ( " # " ) = = 0 ? E . r e p l a c e ( " # " , " " ) : t h i s . t a b I d ( A ( " a : f i r s t - c h i l d " , I ) [ 0 ] ) ; v a r   F = A ( " # " + H ) ; i f ( ! F . l e n g t h ) { F = A ( G . p a n e l T e m p l a t e ) . a t t r ( " i d " , H ) . a d d C l a s s ( G . h i d e C l a s s ) . d a t a ( " d e s t r o y . t a b s " , t r u e ) } F . a d d C l a s s ( G . p a n e l C l a s s ) ; i f ( C > = t h i s . $ l i s . l e n g t h ) { I . a p p e n d T o ( t h i s . e l e m e n t ) ; F . a p p e n d T o ( t h i s . e l e m e n t [ 0 ] . p a r e n t N o d e ) } e l s e { I . i n s e r t B e f o r e ( t h i s . $ l i s [ C ] ) ; F . i n s e r t B e f o r e ( t h i s . $ p a n e l s [ C ] ) } G . d i s a b l e d = A . m a p ( G . d i s a b l e d , f u n c t i o n ( K , J ) { r e t u r n   K > = C ? + + K : K } ) ; t h i s . t a b i f y ( ) ; i f ( t h i s . $ t a b s . l e n g t h = = 1 ) { I . a d d C l a s s ( G . s e l e c t e d C l a s s ) ; F . r e m o v e C l a s s ( G . h i d e C l a s s ) ; v a r   B = A . d a t a ( t h i s . $ t a b s [ 0 ] , " l o a d . t a b s " ) ; i f ( B ) { t h i s . l o a d ( C , B ) } } t h i s . e l e m e n t . t r i g g e r H a n d l e r ( " t a b s a d d " , [ t h i s . u i ( t h i s . $ t a b s [ C ] , t h i s . $ p a n e l s [ C ] ) ] , G . a d d ) } , r e m o v e : f u n c t i o n ( B ) { v a r   D = t h i s . o p t i o n s , E = t h i s . $ l i s . e q ( B ) . r e m o v e ( ) , C = t h i s . $ p a n e l s . e q ( B ) . r e m o v e ( ) ; D . d i s a b l e d = A . m a p ( A . g r e p ( D . d i s a b l e d , f u n c t i o n ( G , F ) { r e t u r n   G ! = B } ) , f u n c t i o n ( G , F ) { r e t u r n   G > = B ? - - G : G } ) ; t h i s . t a b i f y ( ) ; t h i s . e l e m e n t . t r i g g e r H a n d l e r ( " t a b s r e m o v e " , [ t h i s . u i ( E . f i n d ( " a " ) [ 0 ] , C [ 0 ] ) ] , D . r e m o v e ) } , e n a b l e : f u n c t i o n ( B ) { v a r   C = t h i s . o p t i o n s ; i f ( A . i n A r r a y ( B , C . d i s a b l e d ) = = - 1 ) { r e t u r n   } v a r   D = t h i s . $ l i s . e q ( B ) . r e m o v e C l a s s ( C . d i s a b l e d C l a s s ) ; i f ( A . b r o w s e r . s a f a r i ) { D . c s s ( " d i s p l a y " , " i n l i n e - b l o c k " ) ; s e t T i m e o u t ( f u n c t i o n ( ) { D . c s s ( " d i s p l a y " , " b l o c k " ) } , 0 ) } C . d i s a b l e d = A . g r e p ( C . d i s a b l e d , f u n c t i o n ( F , E ) { r e t u r n   F ! = B } ) ; t h i s . e l e m e n t . t r i g g e r H a n d l e r ( " t a b s e n a b l e " , [ t h i s . u i ( t h i s . $ t a b s [ B ] , t h i s . $ p a n e l s [ B ] ) ] , C . e n a b l e ) } , d i s a b l e : f u n c t i o n ( C ) { v a r   B = t h i s , D = t h i s . o p t i o n s ; i f ( C ! = D . s e l e c t e d ) { t h i s . $ l i s . e q ( C ) . a d d C l a s s ( D . d i s a b l e d C l a s s ) ; D . d i s a b l e d . p u s h ( C ) ; D . d i s a b l e d . s o r t ( ) ; t h i s . e l e m e n t . t r i g g e r H a n d l e r ( " t a b s d i s a b l e " , [ t h i s . u i ( t h i s . $ t a b s [ C ] , t h i s . $ p a n e l s [ C ] ) ] , D . d i s a b l e ) } } , s e l e c t : f u n c t i o n ( B ) { i f ( t y p e o f   B = = " s t r i n g " ) { B = t h i s . $ t a b s . i n d e x ( t h i s . $ t a b s . f i l t e r ( " [ h r e f $ = " + B + " ] " ) [ 0 ] ) } t h i s . $ t a b s . e q ( B ) . t r i g g e r ( t h i s . o p t i o n s . e v e n t ) } , l o a d : f u n c t i o n ( G , K ) { v a r   L = t h i s , D = t h i s . o p t i o n s , E = t h i s . $ t a b s . e q ( G ) , J = E [ 0 ] , H = K = = u n d e f i n e d | | K = = = f a l s e , B = E . d a t a ( " l o a d . t a b s " ) ; K = K | | f u n c t i o n ( ) { } ; i f ( ! B | | ! H & & A . d a t a ( J , " c a c h e . t a b s " ) ) { K ( ) ; r e t u r n   } v a r   M = f u n c t i o n ( N ) { v a r   O = A ( N ) , P = O . f i n d ( " * : l a s t " ) ; r e t u r n   P . l e n g t h & & P | | O } ; v a r   C = f u n c t i o n ( ) { L . $ t a b s . f i l t e r ( " . " + D . l o a d i n g C l a s s ) . r e m o v e C l a s s ( D . l o a d i n g C l a s s ) . e a c h ( f u n c t i o n ( ) { i f ( D . s p i n n e r ) { M ( t h i s ) . p a r e n t ( ) . h t m l ( M ( t h i s ) . d a t a ( " l a b e l . t a b s " ) ) } } ) ; L . x h r = n u l l } ; i f ( D . s p i n n e r ) { v a r   I = M ( J ) . h t m l ( ) ; M ( J ) . w r a p I n n e r ( " < e m > < / e m > " ) . f i n d ( " e m " ) . d a t a ( " l a b e l . t a b s " , I ) . h t m l ( D . s p i n n e r ) } v a r   F = A . e x t e n d ( { } , D . a j a x O p t i o n s , { u r l : B , s u c c e s s : f u n c t i o n ( O , N ) { A ( J . h a s h ) . h t m l ( O ) ; C ( ) ; i f ( D . c a c h e ) { A . d a t a ( J , " c a c h e . t a b s " , t r u e ) } A ( L . e l e m e n t ) . t r i g g e r H a n d l e r ( " t a b s l o a d " , [ L . u i ( L . $ t a b s [ G ] , L . $ p a n e l s [ G ] ) ] , D . l o a d ) ; D . a j a x O p t i o n s . s u c c e s s & & D . a j a x O p t i o n s . s u c c e s s ( O , N ) ; K ( ) } } ) ; i f ( t h i s . x h r ) { t h i s . x h r . a b o r t ( ) ; C ( ) } E . a d d C l a s s ( D . l o a d i n g C l a s s ) ; s e t T i m e o u t ( f u n c t i o n ( ) { L . x h r = A . a j a x ( F ) } , 0 ) } , u r l : f u n c t i o n ( C , B ) { t h i s . $ t a b s . e q ( C ) . r e m o v e D a t a ( " c a c h e . t a b s " ) . d a t a ( " l o a d . t a b s " , B ) } , d e s t r o y : f u n c t i o n ( ) { v a r   B = t h i s . o p t i o n s ; t h i s . e l e m e n t . u n b i n d ( " . t a b s " ) . r e m o v e C l a s s ( B . n a v C l a s s ) . r e m o v e D a t a ( " t a b s " ) ; t h i s . $ t a b s . e a c h ( f u n c t i o n ( ) { v a r   C = A . d a t a ( t h i s , " h r e f . t a b s " ) ; i f ( C ) { t h i s . h r e f = C } v a r   D = A ( t h i s ) . u n b i n d ( " . t a b s " ) ; A . e a c h ( [ " h r e f " , " l o a d " , " c a c h e " ] , f u n c t i o n ( E , F ) { D . r e m o v e D a t a ( F + " . t a b s " ) } ) } ) ; t h i s . $ l i s . a d d ( t h i s . $ p a n e l s ) . e a c h ( f u n c t i o n ( ) { i f ( A . d a t a ( t h i s , " d e s t r o y . t a b s " ) ) { A ( t h i s ) . r e m o v e ( ) } e l s e { A ( t h i s ) . r e m o v e C l a s s ( [ B . s e l e c t e d C l a s s , B . u n s e l e c t C l a s s , B . d i s a b l e d C l a s s , B . p a n e l C l a s s , B . h i d e C l a s s ] . j o i n ( "   " ) ) } } ) } } ) ; A . u i . t a b s . d e f a u l t s = { u n s e l e c t : f a l s e , e v e n t : " c l i c k " , d i s a b l e d : [ ] , c o o k i e : n u l l , s p i n n e r : n u l l , c a c h e : f a l s e , i d P r e f i x : " u i - t a b s - " , a j a x O p t i o n s : { } , f x : n u l l , t a b T e m p l a t e : ' < l i > < a   h r e f = " # { h r e f } " > < s p a n > # { l a b e l } < / s p a n > < / a > < / l i > ' , p a n e l T e m p l a t e : " < d i v > < / d i v > " , n a v C l a s s : " u i - t a b s - n a v " , s e l e c t e d C l a s s : " u i - t a b s - s e l e c t e d " , u n s e l e c t C l a s s : " u i - t a b s - u n s e l e c t " , d i s a b l e d C l a s s : " u i - t a b s - d i s a b l e d " , p a n e l C l a s s : " u i - t a b s - p a n e l " , h i d e C l a s s : " u i - t a b s - h i d e " , l o a d i n g C l a s s : " u i - t a b s - l o a d i n g " } ; A . u i . t a b s . g e t t e r = " l e n g t h " ; A . e x t e n d ( A . u i . t a b s . p r o t o t y p e , { r o t a t i o n : n u l l , r o t a t e : f u n c t i o n ( C , F ) { F = F | | f a l s e ; v a r   B = t h i s , E = t h i s . o p t i o n s . s e l e c t e d ; f u n c t i o n   G ( ) { B . r o t a t i o n = s e t I n t e r v a l ( f u n c t i o n ( ) { E = + + E < B . $ t a b s . l e n g t h ? E : 0 ; B . s e l e c t ( E ) } , C ) } f u n c t i o n   D ( H ) { i f ( ! H | | H . c l i e n t X ) { c l e a r I n t e r v a l ( B . r o t a t i o n ) } } i f ( C ) { G ( ) ; i f ( ! F ) { t h i s . $ t a b s . b i n d ( t h i s . o p t i o n s . e v e n t , D ) } e l s e { t h i s . $ t a b s . b i n d ( t h i s . o p t i o n s . e v e n t , f u n c t i o n ( ) { D ( ) ; E = B . o p t i o n s . s e l e c t e d ; G ( ) } ) } } e l s e { D ( ) ; t h i s . $ t a b s . u n b i n d ( t h i s . o p t i o n s . e v e n t , D ) } } } ) } ) ( j Q u e r y ) ; ( f u n c t i o n ( A ) { A . f n . a j a x S u b m i t = f u n c t i o n ( K ) { i f ( t y p e o f   K = = " f u n c t i o n " ) { K = { s u c c e s s : K } } K = A . e x t e n d ( { u r l : t h i s . a t t r ( " a c t i o n " ) | | w i n d o w . l o c a t i o n . t o S t r i n g ( ) , t y p e : t h i s . a t t r ( " m e t h o d " ) | | " G E T " } , K | | { } ) ; v a r   M = { } ; t h i s . t r i g g e r ( " f o r m - p r e - s e r i a l i z e " , [ t h i s , K , M ] ) ; i f ( M . v e t o ) { r e t u r n   t h i s } v a r   G = t h i s . f o r m T o A r r a y ( K . s e m a n t i c ) ; i f ( K . d a t a ) { K . e x t r a D a t a = K . d a t a ; f o r ( v a r   D   i n   K . d a t a ) { G . p u s h ( { n a m e : D , v a l u e : K . d a t a [ D ] } ) } } i f ( K . b e f o r e S u b m i t & & K . b e f o r e S u b m i t ( G , t h i s , K ) = = = f a l s e ) { r e t u r n   t h i s } t h i s . t r i g g e r ( " f o r m - s u b m i t - v a l i d a t e " , [ G , t h i s , K , M ] ) ; i f ( M . v e t o ) { r e t u r n   t h i s } v a r   C = A . p a r a m ( G ) ; i f ( K . t y p e . t o U p p e r C a s e ( ) = = " G E T " ) { K . u r l + = ( K . u r l . i n d e x O f ( " ? " ) > = 0 ? " & " : " ? " ) + C ; K . d a t a = n u l l } e l s e { K . d a t a = C } v a r   L = t h i s , F = [ ] ; i f ( K . r e s e t F o r m ) { F . p u s h ( f u n c t i o n ( ) { L . r e s e t F o r m ( ) } ) } i f ( K . c l e a r F o r m ) { F . p u s h ( f u n c t i o n ( ) { L . c l e a r F o r m ( ) } ) } i f ( ! K . d a t a T y p e & & K . t a r g e t ) { v a r   I = K . s u c c e s s | | f u n c t i o n ( ) { } ; F . p u s h ( f u n c t i o n ( N ) { A ( K . t a r g e t ) . h t m l ( N ) . e a c h ( I , a r g u m e n t s ) } ) } e l s e { i f ( K . s u c c e s s ) { F . p u s h ( K . s u c c e s s ) } } K . s u c c e s s = f u n c t i o n ( Q , O ) { f o r ( v a r   P = 0 , N = F . l e n g t h ; P < N ; P + + ) { F [ P ] ( Q , O , L ) } } ; v a r   B = A ( " i n p u t : f i l e " , t h i s ) . f i e l d V a l u e ( ) ; v a r   J = f a l s e ; f o r ( v a r   E = 0 ; E < B . l e n g t h ; E + + ) { i f ( B [ E ] ) { J = t r u e } } i f ( K . i f r a m e | | J ) { i f ( A . b r o w s e r . s a f a r i & & K . c l o s e K e e p A l i v e ) { A . g e t ( K . c l o s e K e e p A l i v e , H ) } e l s e { H ( ) } } e l s e { A . a j a x ( K ) } t h i s . t r i g g e r ( " f o r m - s u b m i t - n o t i f y " , [ t h i s , K ] ) ; r e t u r n   t h i s ; f u n c t i o n   H ( ) { v a r   Q = L [ 0 ] ; v a r   O = A . e x t e n d ( { } , A . a j a x S e t t i n g s , K ) ; v a r   P = " j q F o r m I O " + ( n e w   D a t e ( ) . g e t T i m e ( ) ) ; v a r   U = A ( ' < i f r a m e   i d = " ' + P + ' "   n a m e = " ' + P + ' "   / > ' ) ; v a r   W = U [ 0 ] ; v a r   X = A . b r o w s e r . o p e r a & & w i n d o w . o p e r a . v e r s i o n ( ) < 9 ; i f ( A . b r o w s e r . m s i e | | X ) { W . s r c = ' j a v a s c r i p t : f a l s e ; d o c u m e n t . w r i t e ( " " ) ; ' } U . c s s ( { p o s i t i o n : " a b s o l u t e " , t o p : " - 1 0 0 0 p x " , l e f t : " - 1 0 0 0 p x " } ) ; v a r   Y = { r e s p o n s e T e x t : n u l l , r e s p o n s e X M L : n u l l , s t a t u s : 0 , s t a t u s T e x t : " n / a " , g e t A l l R e s p o n s e H e a d e r s : f u n c t i o n ( ) { } , g e t R e s p o n s e H e a d e r : f u n c t i o n ( ) { } , s e t R e q u e s t H e a d e r : f u n c t i o n ( ) { } } ; v a r   V = O . g l o b a l ; i f ( V & & ! A . a c t i v e + + ) { A . e v e n t . t r i g g e r ( " a j a x S t a r t " ) } i f ( V ) { A . e v e n t . t r i g g e r ( " a j a x S e n d " , [ Y , O ] ) } v a r   N = 0 ; v a r   R = 0 ; s e t T i m e o u t ( f u n c t i o n ( ) { v a r   c = L . a t t r ( " t a r g e t " ) , Z = L . a t t r ( " a c t i o n " ) ; L . a t t r ( { t a r g e t : P , e n c o d i n g : " m u l t i p a r t / f o r m - d a t a " , e n c t y p e : " m u l t i p a r t / f o r m - d a t a " , m e t h o d : " P O S T " , a c t i o n : O . u r l } ) ; i f ( O . t i m e o u t ) { s e t T i m e o u t ( f u n c t i o n ( ) { R = t r u e ; S ( ) } , O . t i m e o u t ) } v a r   b = [ ] ; t r y { i f ( K . e x t r a D a t a ) { f o r ( v a r   d   i n   K . e x t r a D a t a ) { b . p u s h ( A ( ' < i n p u t   t y p e = " h i d d e n "   n a m e = " ' + d + ' "   v a l u e = " ' + K . e x t r a D a t a [ d ] + ' "   / > ' ) . a p p e n d T o ( Q ) [ 0 ] ) } } U . a p p e n d T o ( " b o d y " ) ; W . a t t a c h E v e n t ? W . a t t a c h E v e n t ( " o n l o a d " , S ) : W . a d d E v e n t L i s t e n e r ( " l o a d " , S , f a l s e ) ; Q . s u b m i t ( ) } f i n a l l y { L . a t t r ( " a c t i o n " , Z ) ; c ? L . a t t r ( " t a r g e t " , c ) : L . r e m o v e A t t r ( " t a r g e t " ) ; A ( b ) . r e m o v e ( ) } } , 1 0 ) ; f u n c t i o n   S ( ) { i f ( N + + ) { r e t u r n   } W . d e t a c h E v e n t ? W . d e t a c h E v e n t ( " o n l o a d " , S ) : W . r e m o v e E v e n t L i s t e n e r ( " l o a d " , S , f a l s e ) ; v a r   a = t r u e ; t r y { i f ( R ) { t h r o w " t i m e o u t " } v a r   b , d ; d = W . c o n t e n t W i n d o w ? W . c o n t e n t W i n d o w . d o c u m e n t : W . c o n t e n t D o c u m e n t ? W . c o n t e n t D o c u m e n t : W . d o c u m e n t ; Y . r e s p o n s e T e x t = d . b o d y ? d . b o d y . i n n e r H T M L : n u l l ; Y . r e s p o n s e X M L = d . X M L D o c u m e n t ? d . X M L D o c u m e n t : d ; Y . g e t R e s p o n s e H e a d e r = f u n c t i o n ( f ) { v a r   e = { " c o n t e n t - t y p e " : O . d a t a T y p e } ; r e t u r n   e [ f ] } ; i f ( O . d a t a T y p e = = " j s o n " | | O . d a t a T y p e = = " s c r i p t " ) { v a r   Z = d . g e t E l e m e n t s B y T a g N a m e ( " t e x t a r e a " ) [ 0 ] ; Y . r e s p o n s e T e x t = Z ? Z . v a l u e : Y . r e s p o n s e T e x t } e l s e { i f ( O . d a t a T y p e = = " x m l " & & ! Y . r e s p o n s e X M L & & Y . r e s p o n s e T e x t ! = n u l l ) { Y . r e s p o n s e X M L = T ( Y . r e s p o n s e T e x t ) } } b = A . h t t p D a t a ( Y , O . d a t a T y p e ) } c a t c h ( c ) { a = f a l s e ; A . h a n d l e E r r o r ( O , Y , " e r r o r " , c ) } i f ( a ) { O . s u c c e s s ( b , " s u c c e s s " ) ; i f ( V ) { A . e v e n t . t r i g g e r ( " a j a x S u c c e s s " , [ Y , O ] ) } } i f ( V ) { A . e v e n t . t r i g g e r ( " a j a x C o m p l e t e " , [ Y , O ] ) } i f ( V & & ! - - A . a c t i v e ) { A . e v e n t . t r i g g e r ( " a j a x S t o p " ) } i f ( O . c o m p l e t e ) { O . c o m p l e t e ( Y , a ? " s u c c e s s " : " e r r o r " ) } s e t T i m e o u t ( f u n c t i o n ( ) { U . r e m o v e ( ) ; Y . r e s p o n s e X M L = n u l l } , 1 0 0 ) } f u n c t i o n   T ( Z , a ) { i f ( w i n d o w . A c t i v e X O b j e c t ) { a = n e w   A c t i v e X O b j e c t ( " M i c r o s o f t . X M L D O M " ) ; a . a s y n c = " f a l s e " ; a . l o a d X M L ( Z ) } e l s e { a = ( n e w   D O M P a r s e r ( ) ) . p a r s e F r o m S t r i n g ( Z , " t e x t / x m l " ) } r e t u r n ( a & & a . d o c u m e n t E l e m e n t & & a . d o c u m e n t E l e m e n t . t a g N a m e ! = " p a r s e r e r r o r " ) ? a : n u l l } } } ; A . f n . a j a x F o r m = f u n c t i o n ( B ) { r e t u r n   t h i s . a j a x F o r m U n b i n d ( ) . b i n d ( " s u b m i t . f o r m - p l u g i n " , f u n c t i o n ( ) { A ( t h i s ) . a j a x S u b m i t ( B ) ; r e t u r n   f a l s e } ) . e a c h ( f u n c t i o n ( ) { A ( " : s u b m i t , i n p u t : i m a g e " , t h i s ) . b i n d ( " c l i c k . f o r m - p l u g i n " , f u n c t i o n ( D ) { v a r   C = t h i s . f o r m ; C . c l k = t h i s ; i f ( t h i s . t y p e = = " i m a g e " ) { i f ( D . o f f s e t X ! = u n d e f i n e d ) { C . c l k _ x = D . o f f s e t X ; C . c l k _ y = D . o f f s e t Y } e l s e { i f ( t y p e o f   A . f n . o f f s e t = = " f u n c t i o n " ) { v a r   E = A ( t h i s ) . o f f s e t ( ) ; C . c l k _ x = D . p a g e X - E . l e f t ; C . c l k _ y = D . p a g e Y - E . t o p } e l s e { C . c l k _ x = D . p a g e X - t h i s . o f f s e t L e f t ; C . c l k _ y = D . p a g e Y - t h i s . o f f s e t T o p } } } s e t T i m e o u t ( f u n c t i o n ( ) { C . c l k = C . c l k _ x = C . c l k _ y = n u l l } , 1 0 ) } ) } ) } ; A . f n . a j a x F o r m U n b i n d = f u n c t i o n ( ) { t h i s . u n b i n d ( " s u b m i t . f o r m - p l u g i n " ) ; r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { A ( " : s u b m i t , i n p u t : i m a g e " , t h i s ) . u n b i n d ( " c l i c k . f o r m - p l u g i n " ) } ) } ; A . f n . f o r m T o A r r a y = f u n c t i o n ( M ) { v a r   L = [ ] ; i f ( t h i s . l e n g t h = = 0 ) { r e t u r n   L } v a r   C = t h i s [ 0 ] ; v a r   G = M ? C . g e t E l e m e n t s B y T a g N a m e ( " * " ) : C . e l e m e n t s ; i f ( ! G ) { r e t u r n   L } f o r ( v a r   H = 0 , J = G . l e n g t h ; H < J ; H + + ) { v a r   D = G [ H ] ; v a r   E = D . n a m e ; i f ( ! E ) { c o n t i n u e } i f ( M & & C . c l k & & D . t y p e = = " i m a g e " ) { i f ( ! D . d i s a b l e d & & C . c l k = = D ) { L . p u s h ( { n a m e : E + " . x " , v a l u e : C . c l k _ x } , { n a m e : E + " . y " , v a l u e : C . c l k _ y } ) } c o n t i n u e } v a r   N = A . f i e l d V a l u e ( D , t r u e ) ; i f ( N & & N . c o n s t r u c t o r = = A r r a y ) { f o r ( v a r   F = 0 , B = N . l e n g t h ; F < B ; F + + ) { L . p u s h ( { n a m e : E , v a l u e : N [ F ] } ) } } e l s e { i f ( N ! = = n u l l & & t y p e o f   N ! = " u n d e f i n e d " ) { L . p u s h ( { n a m e : E , v a l u e : N } ) } } } i f ( ! M & & C . c l k ) { v a r   I = C . g e t E l e m e n t s B y T a g N a m e ( " i n p u t " ) ; f o r ( v a r   H = 0 , J = I . l e n g t h ; H < J ; H + + ) { v a r   K = I [ H ] ; v a r   E = K . n a m e ; i f ( E & & ! K . d i s a b l e d & & K . t y p e = = " i m a g e " & & C . c l k = = K ) { L . p u s h ( { n a m e : E + " . x " , v a l u e : C . c l k _ x } , { n a m e : E + " . y " , v a l u e : C . c l k _ y } ) } } } r e t u r n   L } ; A . f n . f o r m S e r i a l i z e = f u n c t i o n ( B ) { r e t u r n   A . p a r a m ( t h i s . f o r m T o A r r a y ( B ) ) } ; A . f n . f i e l d S e r i a l i z e = f u n c t i o n ( C ) { v a r   B = [ ] ; t h i s . e a c h ( f u n c t i o n ( ) { v a r   G = t h i s . n a m e ; i f ( ! G ) { r e t u r n   } v a r   E = A . f i e l d V a l u e ( t h i s , C ) ; i f ( E & & E . c o n s t r u c t o r = = A r r a y ) { f o r ( v a r   F = 0 , D = E . l e n g t h ; F < D ; F + + ) { B . p u s h ( { n a m e : G , v a l u e : E [ F ] } ) } } e l s e { i f ( E ! = = n u l l & & t y p e o f   E ! = " u n d e f i n e d " ) { B . p u s h ( { n a m e : t h i s . n a m e , v a l u e : E } ) } } } ) ; r e t u r n   A . p a r a m ( B ) } ; A . f n . f i e l d V a l u e = f u n c t i o n ( G ) { f o r ( v a r   F = [ ] , D = 0 , B = t h i s . l e n g t h ; D < B ; D + + ) { v a r   E = t h i s [ D ] ; v a r   C = A . f i e l d V a l u e ( E , G ) ; i f ( C = = = n u l l | | t y p e o f   C = = " u n d e f i n e d " | | ( C . c o n s t r u c t o r = = A r r a y & & ! C . l e n g t h ) ) { c o n t i n u e } C . c o n s t r u c t o r = = A r r a y ? A . m e r g e ( F , C ) : F . p u s h ( C ) } r e t u r n   F } ; A . f i e l d V a l u e = f u n c t i o n ( B , H ) { v a r   D = B . n a m e , M = B . t y p e , N = B . t a g N a m e . t o L o w e r C a s e ( ) ; i f ( t y p e o f   H = = " u n d e f i n e d " ) { H = t r u e } i f ( H & & ( ! D | | B . d i s a b l e d | | M = = " r e s e t " | | M = = " b u t t o n " | | ( M = = " c h e c k b o x " | | M = = " r a d i o " ) & & ! B . c h e c k e d | | ( M = = " s u b m i t " | | M = = " i m a g e " ) & & B . f o r m & & B . f o r m . c l k ! = B | | N = = " s e l e c t " & & B . s e l e c t e d I n d e x = = - 1 ) ) { r e t u r n   n u l l } i f ( N = = " s e l e c t " ) { v a r   I = B . s e l e c t e d I n d e x ; i f ( I < 0 ) { r e t u r n   n u l l } v a r   K = [ ] , C = B . o p t i o n s ; v a r   F = ( M = = " s e l e c t - o n e " ) ; v a r   J = ( F ? I + 1 : C . l e n g t h ) ; f o r ( v a r   E = ( F ? I : 0 ) ; E < J ; E + + ) { v a r   G = C [ E ] ; i f ( G . s e l e c t e d ) { v a r   L = A . b r o w s e r . m s i e & & ! ( G . a t t r i b u t e s . v a l u e . s p e c i f i e d ) ? G . t e x t : G . v a l u e ; i f ( F ) { r e t u r n   L } K . p u s h ( L ) } } r e t u r n   K } r e t u r n   B . v a l u e } ; A . f n . c l e a r F o r m = f u n c t i o n ( ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { A ( " i n p u t , s e l e c t , t e x t a r e a " , t h i s ) . c l e a r F i e l d s ( ) } ) } ; A . f n . c l e a r F i e l d s = A . f n . c l e a r I n p u t s = f u n c t i o n ( ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { v a r   C = t h i s . t y p e , B = t h i s . t a g N a m e . t o L o w e r C a s e ( ) ; i f ( C = = " t e x t " | | C = = " p a s s w o r d " | | B = = " t e x t a r e a " ) { t h i s . v a l u e = " " } e l s e { i f ( C = = " c h e c k b o x " | | C = = " r a d i o " ) { t h i s . c h e c k e d = f a l s e } e l s e { i f ( B = = " s e l e c t " ) { t h i s . s e l e c t e d I n d e x = - 1 } } } } ) } ; A . f n . r e s e t F o r m = f u n c t i o n ( ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { i f ( t y p e o f   t h i s . r e s e t = = " f u n c t i o n " | | ( t y p e o f   t h i s . r e s e t = = " o b j e c t " & & ! t h i s . r e s e t . n o d e T y p e ) ) { t h i s . r e s e t ( ) } } ) } ; A . f n . e n a b l e = f u n c t i o n ( B ) { i f ( B = = u n d e f i n e d ) { B = t r u e } r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { t h i s . d i s a b l e d = ! B } ) } ; A . f n . s e l e c t = f u n c t i o n ( B ) { i f ( B = = u n d e f i n e d ) { B = t r u e } r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { v a r   C = t h i s . t y p e ; i f ( C = = " c h e c k b o x " | | C = = " r a d i o " ) { t h i s . c h e c k e d = B } e l s e { i f ( t h i s . t a g N a m e . t o L o w e r C a s e ( ) = = " o p t i o n " ) { v a r   D = A ( t h i s ) . p a r e n t ( " s e l e c t " ) ; i f ( B & & D [ 0 ] & & D [ 0 ] . t y p e = = " s e l e c t - o n e " ) { D . f i n d ( " o p t i o n " ) . s e l e c t ( f a l s e ) } t h i s . s e l e c t e d = B } } } ) } } ) ( j Q u e r y ) ; ( f u n c t i o n ( $ ) { $ . e x t e n d ( { m e t a d a t a : { d e f a u l t s : { t y p e : " c l a s s " , n a m e : " m e t a d a t a " , c r e : / ( { . * } ) / , s i n g l e : " m e t a d a t a " } , s e t T y p e : f u n c t i o n ( t y p e , n a m e ) { t h i s . d e f a u l t s . t y p e = t y p e ; t h i s . d e f a u l t s . n a m e = n a m e } , g e t : f u n c t i o n ( e l e m , o p t s ) { v a r   s e t t i n g s = $ . e x t e n d ( { } , t h i s . d e f a u l t s , o p t s ) ; i f ( ! s e t t i n g s . s i n g l e . l e n g t h ) { s e t t i n g s . s i n g l e = " m e t a d a t a " } v a r   d a t a = $ . d a t a ( e l e m , s e t t i n g s . s i n g l e ) ; i f ( d a t a ) { r e t u r n   d a t a } d a t a = " { } " ; i f ( s e t t i n g s . t y p e = = " c l a s s " ) { v a r   m = s e t t i n g s . c r e . e x e c ( e l e m . c l a s s N a m e ) ; i f ( m ) { d a t a = m [ 1 ] } } e l s e { i f ( s e t t i n g s . t y p e = = " e l e m " ) { i f ( ! e l e m . g e t E l e m e n t s B y T a g N a m e ) { r e t u r n   u n d e f i n e d } v a r   e = e l e m . g e t E l e m e n t s B y T a g N a m e ( s e t t i n g s . n a m e ) ; i f ( e . l e n g t h ) { d a t a = $ . t r i m ( e [ 0 ] . i n n e r H T M L ) } } e l s e { i f ( e l e m . g e t A t t r i b u t e ! = u n d e f i n e d ) { v a r   a t t r = e l e m . g e t A t t r i b u t e ( s e t t i n g s . n a m e ) ; i f ( a t t r ) { d a t a = a t t r } } } } i f ( d a t a . i n d e x O f ( " { " ) < 0 ) { d a t a = " { " + d a t a + " } " } d a t a = e v a l ( " ( " + d a t a + " ) " ) ; $ . d a t a ( e l e m , s e t t i n g s . s i n g l e , d a t a ) ; r e t u r n   d a t a } } } ) ; $ . f n . m e t a d a t a = f u n c t i o n ( o p t s ) { r e t u r n   $ . m e t a d a t a . g e t ( t h i s [ 0 ] , o p t s ) } } ) ( j Q u e r y ) ; j Q u e r y . e x t e n d ( j Q u e r y . f n , { v a l i d a t e : f u n c t i o n ( A ) { i f ( ! t h i s . l e n g t h ) { A & & A . d e b u g & & w i n d o w . c o n s o l e & & c o n s o l e . w a r n ( " n o t h i n g   s e l e c t e d ,   c a n ' t   v a l i d a t e ,   r e t u r n i n g   n o t h i n g " ) ; r e t u r n   } v a r   B = j Q u e r y . d a t a ( t h i s [ 0 ] , " v a l i d a t o r " ) ; i f ( B ) { r e t u r n   B } B = n e w   j Q u e r y . v a l i d a t o r ( A , t h i s [ 0 ] ) ; j Q u e r y . d a t a ( t h i s [ 0 ] , " v a l i d a t o r " , B ) ; i f ( B . s e t t i n g s . o n s u b m i t ) { t h i s . f i n d ( " i n p u t . c a n c e l : s u b m i t " ) . c l i c k ( f u n c t i o n ( ) { B . c a n c e l S u b m i t = t r u e } ) ; t h i s . s u b m i t ( f u n c t i o n ( C ) { i f ( B . s e t t i n g s . d e b u g ) { C . p r e v e n t D e f a u l t ( ) } f u n c t i o n   D ( ) { i f ( B . s e t t i n g s . s u b m i t H a n d l e r ) { B . s e t t i n g s . s u b m i t H a n d l e r . c a l l ( B , B . c u r r e n t F o r m ) ; r e t u r n   f a l s e } r e t u r n   t r u e } i f ( B . c a n c e l S u b m i t ) { B . c a n c e l S u b m i t = f a l s e ; r e t u r n   D ( ) } i f ( B . f o r m ( ) ) { i f ( B . p e n d i n g R e q u e s t ) { B . f o r m S u b m i t t e d = t r u e ; r e t u r n   f a l s e } r e t u r n   D ( ) } e l s e { B . f o c u s I n v a l i d ( ) ; r e t u r n   f a l s e } } ) } r e t u r n   B } , v a l i d : f u n c t i o n ( ) { i f ( j Q u e r y ( t h i s [ 0 ] ) . i s ( " f o r m " ) ) { r e t u r n   t h i s . v a l i d a t e ( ) . f o r m ( ) } e l s e { v a r   B = f a l s e ; v a r   A = j Q u e r y ( t h i s [ 0 ] . f o r m ) . v a l i d a t e ( ) ; t h i s . e a c h ( f u n c t i o n ( ) { B | = A . e l e m e n t ( t h i s ) } ) ; r e t u r n   B } } , r e m o v e A t t r s : f u n c t i o n ( C ) { v a r   A = { } , B = t h i s ; $ . e a c h ( C . s p l i t ( / \ s / ) , f u n c t i o n ( ) { A [ t h i s ] = B . a t t r ( t h i s ) ; B . r e m o v e A t t r ( t h i s ) } ) ; r e t u r n   A } , r u l e s : f u n c t i o n ( G , C ) { v a r   B = t h i s [ 0 ] ; i f ( G ) { v a r   H = j Q u e r y . d a t a ( B . f o r m , " v a l i d a t o r " ) . s e t t i n g s . r u l e s ; v a r   E = j Q u e r y . v a l i d a t o r . s t a t i c R u l e s ( B ) ; s w i t c h ( G ) { c a s e " a d d " : $ . e x t e n d ( E , j Q u e r y . v a l i d a t o r . n o r m a l i z e R u l e ( C ) ) ; H [ B . n a m e ] = E ; b r e a k ; c a s e " r e m o v e " : i f ( ! C ) { d e l e t e   H [ B . n a m e ] ; r e t u r n   E } v a r   A = { } ; $ . e a c h ( C . s p l i t ( / \ s / ) , f u n c t i o n ( I , J ) { A [ J ] = E [ J ] ; d e l e t e   E [ J ] } ) ; r e t u r n   A } } v a r   D = j Q u e r y . v a l i d a t o r . n o r m a l i z e R u l e s ( j Q u e r y . e x t e n d ( { } , j Q u e r y . v a l i d a t o r . m e t a d a t a R u l e s ( B ) , j Q u e r y . v a l i d a t o r . c l a s s R u l e s ( B ) , j Q u e r y . v a l i d a t o r . a t t r i b u t e R u l e s ( B ) , j Q u e r y . v a l i d a t o r . s t a t i c R u l e s ( B ) ) , B ) ; i f ( D . r e q u i r e d ) { v a r   F = D . r e q u i r e d ; d e l e t e   D . r e q u i r e d ; D = $ . e x t e n d ( { r e q u i r e d : F } , D ) } r e t u r n   D } , p u s h : f u n c t i o n ( A ) { r e t u r n   t h i s . s e t A r r a y ( t h i s . a d d ( A ) . g e t ( ) ) } } ) ; j Q u e r y . e x t e n d ( j Q u e r y . e x p r [ " : " ] , { b l a n k : " ! j Q u e r y . t r i m ( a . v a l u e ) " , f i l l e d : " ! ! j Q u e r y . t r i m ( a . v a l u e ) " , u n c h e c k e d : " ! a . c h e c k e d " } ) ; j Q u e r y . f o r m a t = f u n c t i o n ( A , B ) { i f ( a r g u m e n t s . l e n g t h = = 1 ) { r e t u r n   f u n c t i o n ( ) { v a r   C = j Q u e r y . m a k e A r r a y ( a r g u m e n t s ) ; C . u n s h i f t ( A ) ; r e t u r n   j Q u e r y . f o r m a t . a p p l y ( t h i s , C ) } } i f ( a r g u m e n t s . l e n g t h > 2 & & B . c o n s t r u c t o r ! = A r r a y ) { B = j Q u e r y . m a k e A r r a y ( a r g u m e n t s ) . s l i c e ( 1 ) } i f ( B . c o n s t r u c t o r ! = A r r a y ) { B = [ B ] } j Q u e r y . e a c h ( B , f u n c t i o n ( C , D ) { A = A . r e p l a c e ( n e w   R e g E x p ( " \ \ { " + C + " \ \ } " , " g " ) , D ) } ) ; r e t u r n   A } ; j Q u e r y . v a l i d a t o r = f u n c t i o n ( A , B ) { t h i s . s e t t i n g s = j Q u e r y . e x t e n d ( { } , j Q u e r y . v a l i d a t o r . d e f a u l t s , A ) ; t h i s . c u r r e n t F o r m = B ; t h i s . i n i t ( ) } ; j Q u e r y . e x t e n d ( j Q u e r y . v a l i d a t o r , { d e f a u l t s : { m e s s a g e s : { } , g r o u p s : { } , r u l e s : { } , e r r o r C l a s s : " e r r o r " , e r r o r E l e m e n t : " l a b e l " , f o c u s I n v a l i d : t r u e , e r r o r C o n t a i n e r : j Q u e r y ( [ ] ) , e r r o r L a b e l C o n t a i n e r : j Q u e r y ( [ ] ) , o n s u b m i t : t r u e , i g n o r e : [ ] , o n f o c u s i n : f u n c t i o n ( A ) { t h i s . l a s t A c t i v e = A ; i f ( t h i s . s e t t i n g s . f o c u s C l e a n u p & & ! t h i s . b l o c k F o c u s C l e a n u p ) { t h i s . s e t t i n g s . u n h i g h l i g h t & & t h i s . s e t t i n g s . u n h i g h l i g h t . c a l l ( t h i s , A , t h i s . s e t t i n g s . e r r o r C l a s s ) ; t h i s . e r r o r s F o r ( A ) . h i d e ( ) } } , o n f o c u s o u t : f u n c t i o n ( A ) { i f ( ! t h i s . c h e c k a b l e ( A ) & & ( A . n a m e   i n   t h i s . s u b m i t t e d | | ! t h i s . o p t i o n a l ( A ) ) ) { t h i s . e l e m e n t ( A ) } } , o n k e y u p : f u n c t i o n ( A ) { i f ( A . n a m e   i n   t h i s . s u b m i t t e d | | A = = t h i s . l a s t E l e m e n t ) { t h i s . e l e m e n t ( A ) } } , o n c l i c k : f u n c t i o n ( A ) { i f ( A . n a m e   i n   t h i s . s u b m i t t e d ) { t h i s . e l e m e n t ( A ) } } , h i g h l i g h t : f u n c t i o n ( B , A ) { j Q u e r y ( B ) . a d d C l a s s ( A ) } , u n h i g h l i g h t : f u n c t i o n ( B , A ) { j Q u e r y ( B ) . r e m o v e C l a s s ( A ) } } , s e t D e f a u l t s : f u n c t i o n ( A ) { j Q u e r y . e x t e n d ( j Q u e r y . v a l i d a t o r . d e f a u l t s , A ) } , m e s s a g e s : { r e q u i r e d : " T h i s   f i e l d   i s   r e q u i r e d . " , r e m o t e : " P l e a s e   f i x   t h i s   f i e l d . " , e m a i l : " P l e a s e   e n t e r   a   v a l i d   e m a i l   a d d r e s s . " , u r l : " P l e a s e   e n t e r   a   v a l i d   U R L . " , d a t e : " P l e a s e   e n t e r   a   v a l i d   d a t e . " , d a t e I S O : " P l e a s e   e n t e r   a   v a l i d   d a t e   ( I S O ) . " , d a t e D E : " B i t t e   g e b e n   S i e   e i n   g %]%l t i g e s   D a t u m   e i n . " , n u m b e r : " P l e a s e   e n t e r   a   v a l i d   n u m b e r . " , n u m b e r D E : " B i t t e   g e b e n   S i e   e i n e   N u m m e r   e i n . " , d i g i t s : " P l e a s e   e n t e r   o n l y   d i g i t s " , c r e d i t c a r d : " P l e a s e   e n t e r   a   v a l i d   c r e d i t   c a r d . " , e q u a l T o : " P l e a s e   e n t e r   t h e   s a m e   v a l u e   a g a i n . " , a c c e p t : " P l e a s e   e n t e r   a   v a l u e   w i t h   a   v a l i d   e x t e n s i o n . " , m a x l e n g t h : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   n o   m o r e   t h a n   { 0 }   c h a r a c t e r s . " ) , m a x L e n g t h : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   n o   m o r e   t h a n   { 0 }   c h a r a c t e r s . " ) , m i n l e n g t h : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a t   l e a s t   { 0 }   c h a r a c t e r s . " ) , m i n L e n g t h : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a t   l e a s t   { 0 }   c h a r a c t e r s . " ) , r a n g e l e n g t h : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a   v a l u e   b e t w e e n   { 0 }   a n d   { 1 }   c h a r a c t e r s   l o n g . " ) , r a n g e L e n g t h : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a   v a l u e   b e t w e e n   { 0 }   a n d   { 1 }   c h a r a c t e r s   l o n g . " ) , r a n g e V a l u e : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a   v a l u e   b e t w e e n   { 0 }   a n d   { 1 } . " ) , r a n g e : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a   v a l u e   b e t w e e n   { 0 }   a n d   { 1 } . " ) , m a x V a l u e : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a   v a l u e   l e s s   t h a n   o r   e q u a l   t o   { 0 } . " ) , m a x : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a   v a l u e   l e s s   t h a n   o r   e q u a l   t o   { 0 } . " ) , m i n V a l u e : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a   v a l u e   g r e a t e r   t h a n   o r   e q u a l   t o   { 0 } . " ) , m i n : j Q u e r y . f o r m a t ( " P l e a s e   e n t e r   a   v a l u e   g r e a t e r   t h a n   o r   e q u a l   t o   { 0 } . " ) } , a u t o C r e a t e R a n g e s : f a l s e , p r o t o t y p e : { i n i t : f u n c t i o n ( ) { t h i s . l a b e l C o n t a i n e r = j Q u e r y ( t h i s . s e t t i n g s . e r r o r L a b e l C o n t a i n e r ) ; t h i s . e r r o r C o n t e x t = t h i s . l a b e l C o n t a i n e r . l e n g t h & & t h i s . l a b e l C o n t a i n e r | | j Q u e r y ( t h i s . c u r r e n t F o r m ) ; t h i s . c o n t a i n e r s = j Q u e r y ( t h i s . s e t t i n g s . e r r o r C o n t a i n e r ) . a d d ( t h i s . s e t t i n g s . e r r o r L a b e l C o n t a i n e r ) ; t h i s . s u b m i t t e d = { } ; t h i s . v a l u e C a c h e = { } ; t h i s . p e n d i n g R e q u e s t = 0 ; t h i s . p e n d i n g = { } ; t h i s . i n v a l i d = { } ; t h i s . r e s e t ( ) ; v a r   A = ( t h i s . g r o u p s = { } ) ; j Q u e r y . e a c h ( t h i s . s e t t i n g s . g r o u p s , f u n c t i o n ( D , E ) { j Q u e r y . e a c h ( E . s p l i t ( / \ s / ) , f u n c t i o n ( G , F ) { A [ F ] = D } ) } ) ; v a r   C = t h i s . s e t t i n g s . r u l e s ; j Q u e r y . e a c h ( C , f u n c t i o n ( D , E ) { C [ D ] = j Q u e r y . v a l i d a t o r . n o r m a l i z e R u l e ( E ) } ) ; f u n c t i o n   B ( E ) { v a r   D = j Q u e r y . d a t a ( t h i s [ 0 ] . f o r m , " v a l i d a t o r " ) ; D . s e t t i n g s [ " o n " + E . t y p e ] & & D . s e t t i n g s [ " o n " + E . t y p e ] . c a l l ( D , t h i s [ 0 ] ) } j Q u e r y ( t h i s . c u r r e n t F o r m ) . d e l e g a t e ( " f o c u s i n   f o c u s o u t   k e y u p " , " : t e x t ,   : p a s s w o r d ,   : f i l e ,   s e l e c t ,   t e x t a r e a " , B ) . d e l e g a t e ( " c l i c k " , " : r a d i o ,   : c h e c k b o x " , B ) } , f o r m : f u n c t i o n ( ) { t h i s . p r e p a r e F o r m ( ) ; v a r   B = t h i s . e l e m e n t s ( ) ; f o r ( v a r   A = 0 ; B [ A ] ; A + + ) { t h i s . c h e c k ( B [ A ] ) } j Q u e r y . e x t e n d ( t h i s . s u b m i t t e d , t h i s . e r r o r M a p ) ; t h i s . i n v a l i d = j Q u e r y . e x t e n d ( { } , t h i s . e r r o r M a p ) ; i f ( ! t h i s . v a l i d ( ) ) { j Q u e r y ( t h i s . c u r r e n t F o r m ) . t r i g g e r H a n d l e r ( " i n v a l i d - f o r m . v a l i d a t e " , [ t h i s ] ) } t h i s . s h o w E r r o r s ( ) ; r e t u r n   t h i s . v a l i d ( ) } , e l e m e n t : f u n c t i o n ( B ) { B = t h i s . c l e a n ( B ) ; t h i s . l a s t E l e m e n t = B ; t h i s . p r e p a r e E l e m e n t ( B ) ; v a r   A = t h i s . c h e c k ( B ) ; i f ( A ) { d e l e t e   t h i s . i n v a l i d [ B . n a m e ] } e l s e { t h i s . i n v a l i d [ B . n a m e ] = t r u e } i f ( ! t h i s . n u m b e r O f I n v a l i d s ( ) ) { t h i s . t o H i d e . p u s h ( t h i s . c o n t a i n e r s ) } t h i s . s h o w E r r o r s ( ) ; r e t u r n   A } , s h o w E r r o r s : f u n c t i o n ( B ) { i f ( B ) { j Q u e r y . e x t e n d ( t h i s . e r r o r M a p , B ) ; t h i s . e r r o r L i s t = [ ] ; f o r ( v a r   A   i n   B ) { t h i s . e r r o r L i s t . p u s h ( { m e s s a g e : B [ A ] , e l e m e n t : t h i s . f i n d B y N a m e ( A ) [ 0 ] } ) } t h i s . s u c c e s s L i s t = j Q u e r y . g r e p ( t h i s . s u c c e s s L i s t , f u n c t i o n ( C ) { r e t u r n   ! ( C . n a m e   i n   B ) } ) } t h i s . s e t t i n g s . s h o w E r r o r s ? t h i s . s e t t i n g s . s h o w E r r o r s . c a l l ( t h i s , t h i s . e r r o r M a p , t h i s . e r r o r L i s t ) : t h i s . d e f a u l t S h o w E r r o r s ( ) } , r e s e t F o r m : f u n c t i o n ( ) { i f ( j Q u e r y . f n . r e s e t F o r m ) { j Q u e r y ( t h i s . c u r r e n t F o r m ) . r e s e t F o r m ( ) } t h i s . p r e p a r e F o r m ( ) ; t h i s . h i d e E r r o r s ( ) ; t h i s . e l e m e n t s ( ) . r e m o v e C l a s s ( t h i s . s e t t i n g s . e r r o r C l a s s ) } , n u m b e r O f I n v a l i d s : f u n c t i o n ( ) { r e t u r n   t h i s . o b j e c t L e n g t h ( t h i s . i n v a l i d ) } , o b j e c t L e n g t h : f u n c t i o n ( C ) { v a r   B = 0 ; f o r ( v a r   A   i n   C ) { B + + } r e t u r n   B } , h i d e E r r o r s : f u n c t i o n ( ) { t h i s . a d d W r a p p e r ( t h i s . t o H i d e ) . h i d e ( ) } , v a l i d : f u n c t i o n ( ) { r e t u r n   t h i s . s i z e ( ) = = 0 } , s i z e : f u n c t i o n ( ) { r e t u r n   t h i s . e r r o r L i s t . l e n g t h } , f o c u s I n v a l i d : f u n c t i o n ( ) { i f ( t h i s . s e t t i n g s . f o c u s I n v a l i d ) { t r y { j Q u e r y ( t h i s . f i n d L a s t A c t i v e ( ) | | t h i s . e r r o r L i s t . l e n g t h & & t h i s . e r r o r L i s t [ 0 ] . e l e m e n t | | [ ] ) . f i l t e r ( " : v i s i b l e " ) . f o c u s ( ) } c a t c h ( A ) { } } } , f i n d L a s t A c t i v e : f u n c t i o n ( ) { v a r   A = t h i s . l a s t A c t i v e ; r e t u r n   A & & j Q u e r y . g r e p ( t h i s . e r r o r L i s t , f u n c t i o n ( B ) { r e t u r n   B . e l e m e n t . n a m e = = A . n a m e } ) . l e n g t h = = 1 & & A } , e l e m e n t s : f u n c t i o n ( ) { v a r   B = t h i s , A = { } ; r e t u r n   j Q u e r y ( [ ] ) . a d d ( t h i s . c u r r e n t F o r m . e l e m e n t s ) . f i l t e r ( " i n p u t ,   s e l e c t ,   t e x t a r e a " ) . n o t ( " : s u b m i t ,   : r e s e t ,   [ d i s a b l e d ] " ) . n o t ( t h i s . s e t t i n g s . i g n o r e ) . f i l t e r ( f u n c t i o n ( ) { ! t h i s . n a m e & & B . s e t t i n g s . d e b u g & & w i n d o w . c o n s o l e & & c o n s o l e . e r r o r ( " % o   h a s   n o   n a m e   a s s i g n e d " , t h i s ) ; i f ( t h i s . n a m e   i n   A | | ! B . o b j e c t L e n g t h ( $ ( t h i s ) . r u l e s ( ) ) ) { r e t u r n   f a l s e } A [ t h i s . n a m e ] = t r u e ; r e t u r n   t r u e } ) } , c l e a n : f u n c t i o n ( A ) { r e t u r n   j Q u e r y ( A ) [ 0 ] } , e r r o r s : f u n c t i o n ( ) { r e t u r n   j Q u e r y ( t h i s . s e t t i n g s . e r r o r E l e m e n t + " . " + t h i s . s e t t i n g s . e r r o r C l a s s , t h i s . e r r o r C o n t e x t ) } , r e s e t : f u n c t i o n ( ) { t h i s . s u c c e s s L i s t = [ ] ; t h i s . e r r o r L i s t = [ ] ; t h i s . e r r o r M a p = { } ; t h i s . t o S h o w = j Q u e r y ( [ ] ) ; t h i s . t o H i d e = j Q u e r y ( [ ] ) ; t h i s . f o r m S u b m i t t e d = f a l s e } , p r e p a r e F o r m : f u n c t i o n ( ) { t h i s . r e s e t ( ) ; t h i s . t o H i d e = t h i s . e r r o r s ( ) . p u s h ( t h i s . c o n t a i n e r s ) } , p r e p a r e E l e m e n t : f u n c t i o n ( A ) { t h i s . r e s e t ( ) ; t h i s . t o H i d e = t h i s . e r r o r s F o r ( A ) } , c h e c k : f u n c t i o n ( B ) { B = t h i s . c l e a n ( B ) ; t h i s . s e t t i n g s . u n h i g h l i g h t & & t h i s . s e t t i n g s . u n h i g h l i g h t . c a l l ( t h i s , B , t h i s . s e t t i n g s . e r r o r C l a s s ) ; i f ( t h i s . c h e c k a b l e ( B ) ) { B = t h i s . f i n d B y N a m e ( B . n a m e ) [ 0 ] } v a r   F = $ ( B ) . r u l e s ( ) ; v a r   C = f a l s e ; f o r ( m e t h o d   i n   F ) { v a r   E = { m e t h o d : m e t h o d , p a r a m e t e r s : F [ m e t h o d ] } ; t r y { v a r   A = j Q u e r y . v a l i d a t o r . m e t h o d s [ m e t h o d ] . c a l l ( t h i s , j Q u e r y . t r i m ( B . v a l u e ) , B , E . p a r a m e t e r s ) ; i f ( A = = " d e p e n d e n c y - m i s m a t c h " ) { C = t r u e ; c o n t i n u e } C = f a l s e ; i f ( A = = " p e n d i n g " ) { t h i s . t o H i d e = t h i s . t o H i d e . n o t ( t h i s . e r r o r s F o r ( B ) ) ; r e t u r n   } i f ( ! A ) { t h i s . f o r m a t A n d A d d ( B , E ) ; r e t u r n   f a l s e } } c a t c h ( D ) { t h i s . s e t t i n g s . d e b u g & & w i n d o w . c o n s o l e & & c o n s o l e . l o g ( " e x c e p t i o n   o c c u r e d   w h e n   c h e c k i n g   e l e m e n t   " + B . i d + " ,   c h e c k   t h e   ' " + E . m e t h o d + " '   m e t h o d " ) ; t h r o w   D } } i f ( C ) { r e t u r n   } i f ( t h i s . o b j e c t L e n g t h ( F ) ) { t h i s . s u c c e s s L i s t . p u s h ( B ) } r e t u r n   t r u e } , c u s t o m M e s s a g e : f u n c t i o n ( B , C ) { v a r   A = t h i s . s e t t i n g s . m e s s a g e s [ B ] ; r e t u r n   A & & ( A . c o n s t r u c t o r = = S t r i n g ? A : A [ C ] ) } , f i n d D e f i n e d : f u n c t i o n ( ) { f o r ( v a r   A = 0 ; A < a r g u m e n t s . l e n g t h ; A + + ) { i f ( a r g u m e n t s [ A ] ! = = u n d e f i n e d ) { r e t u r n   a r g u m e n t s [ A ] } } r e t u r n   u n d e f i n e d } , d e f a u l t M e s s a g e : f u n c t i o n ( A , B ) { r e t u r n   t h i s . f i n d D e f i n e d ( t h i s . c u s t o m M e s s a g e ( A . n a m e , B ) , A . t i t l e | | u n d e f i n e d , j Q u e r y . v a l i d a t o r . m e s s a g e s [ B ] , " < s t r o n g > W a r n i n g :   N o   m e s s a g e   d e f i n e d   f o r   " + A . n a m e + " < / s t r o n g > " ) } , f o r m a t A n d A d d : f u n c t i o n ( A , C ) { v a r   B = t h i s . d e f a u l t M e s s a g e ( A , C . m e t h o d ) ; i f ( t y p e o f   B = = " f u n c t i o n " ) { B = B . c a l l ( t h i s , C . p a r a m e t e r s , A ) } t h i s . e r r o r L i s t . p u s h ( { m e s s a g e : B , e l e m e n t : A } ) ; t h i s . e r r o r M a p [ A . n a m e ] = B ; t h i s . s u b m i t t e d [ A . n a m e ] = B } , a d d W r a p p e r : f u n c t i o n ( A ) { i f ( t h i s . s e t t i n g s . w r a p p e r ) { A . p u s h ( A . p a r e n t s ( t h i s . s e t t i n g s . w r a p p e r ) ) } r e t u r n   A } , d e f a u l t S h o w E r r o r s : f u n c t i o n ( ) { f o r ( v a r   B = 0 ; t h i s . e r r o r L i s t [ B ] ; B + + ) { v a r   A = t h i s . e r r o r L i s t [ B ] ; t h i s . s e t t i n g s . h i g h l i g h t & & t h i s . s e t t i n g s . h i g h l i g h t . c a l l ( t h i s , A . e l e m e n t , t h i s . s e t t i n g s . e r r o r C l a s s ) ; t h i s . s h o w L a b e l ( A . e l e m e n t , A . m e s s a g e ) } i f ( t h i s . e r r o r L i s t . l e n g t h ) { t h i s . t o S h o w . p u s h ( t h i s . c o n t a i n e r s ) } i f ( t h i s . s e t t i n g s . s u c c e s s ) { f o r ( v a r   B = 0 ; t h i s . s u c c e s s L i s t [ B ] ; B + + ) { t h i s . s h o w L a b e l ( t h i s . s u c c e s s L i s t [ B ] ) } } t h i s . t o H i d e = t h i s . t o H i d e . n o t ( t h i s . t o S h o w ) ; t h i s . h i d e E r r o r s ( ) ; t h i s . a d d W r a p p e r ( t h i s . t o S h o w ) . s h o w ( ) } , s h o w L a b e l : f u n c t i o n ( B , C ) { v a r   A = t h i s . e r r o r s F o r ( B ) ; i f ( A . l e n g t h ) { A . r e m o v e C l a s s ( ) . a d d C l a s s ( t h i s . s e t t i n g s . e r r o r C l a s s ) ; A . a t t r ( " g e n e r a t e d " ) & & A . h t m l ( C ) } e l s e { A = j Q u e r y ( " < " + t h i s . s e t t i n g s . e r r o r E l e m e n t + " / > " ) . a t t r ( { " f o r " : t h i s . i d O r N a m e ( B ) , g e n e r a t e d : t r u e } ) . a d d C l a s s ( t h i s . s e t t i n g s . e r r o r C l a s s ) . h t m l ( C | | " " ) ; i f ( t h i s . s e t t i n g s . w r a p p e r ) { A = A . h i d e ( ) . s h o w ( ) . w r a p ( " < " + t h i s . s e t t i n g s . w r a p p e r + " > " ) . p a r e n t ( ) } i f ( ! t h i s . l a b e l C o n t a i n e r . a p p e n d ( A ) . l e n g t h ) { t h i s . s e t t i n g s . e r r o r P l a c e m e n t ? t h i s . s e t t i n g s . e r r o r P l a c e m e n t ( A , j Q u e r y ( B ) ) : A . i n s e r t A f t e r ( B ) } } i f ( ! C & & t h i s . s e t t i n g s . s u c c e s s ) { A . t e x t ( " " ) ; t y p e o f   t h i s . s e t t i n g s . s u c c e s s = = " s t r i n g " ? A . a d d C l a s s ( t h i s . s e t t i n g s . s u c c e s s ) : t h i s . s e t t i n g s . s u c c e s s ( A ) } t h i s . t o S h o w . p u s h ( A ) } , e r r o r s F o r : f u n c t i o n ( A ) { r e t u r n   t h i s . e r r o r s ( ) . f i l t e r ( " [ @ f o r = ' " + t h i s . i d O r N a m e ( A ) + " ' ] " ) } , i d O r N a m e : f u n c t i o n ( A ) { r e t u r n   t h i s . g r o u p s [ A . n a m e ] | | ( t h i s . c h e c k a b l e ( A ) ? A . n a m e : A . i d | | A . n a m e ) } , c h e c k a b l e : f u n c t i o n ( A ) { r e t u r n / r a d i o | c h e c k b o x / i . t e s t ( A . t y p e ) } , f i n d B y N a m e : f u n c t i o n ( A ) { v a r   B = t h i s . c u r r e n t F o r m ; r e t u r n   j Q u e r y ( d o c u m e n t . g e t E l e m e n t s B y N a m e ( A ) ) . m a p ( f u n c t i o n ( C , D ) { r e t u r n   D . f o r m = = B & & D . n a m e = = A & & D | | n u l l } ) } , g e t L e n g t h : f u n c t i o n ( B , A ) { s w i t c h ( A . n o d e N a m e . t o L o w e r C a s e ( ) ) { c a s e " s e l e c t " : r e t u r n   j Q u e r y ( " o p t i o n : s e l e c t e d " , A ) . l e n g t h ; c a s e " i n p u t " : i f ( t h i s . c h e c k a b l e ( A ) ) { r e t u r n   t h i s . f i n d B y N a m e ( A . n a m e ) . f i l t e r ( " : c h e c k e d " ) . l e n g t h } } r e t u r n   B . l e n g t h } , d e p e n d : f u n c t i o n ( B , A ) { r e t u r n   t h i s . d e p e n d T y p e s [ t y p e o f   B ] ? t h i s . d e p e n d T y p e s [ t y p e o f   B ] ( B , A ) : t r u e } , d e p e n d T y p e s : { " b o o l e a n " : f u n c t i o n ( B , A ) { r e t u r n   B } , s t r i n g : f u n c t i o n ( B , A ) { r e t u r n   ! ! j Q u e r y ( B , A . f o r m ) . l e n g t h } , " f u n c t i o n " : f u n c t i o n ( B , A ) { r e t u r n   B ( A ) } } , o p t i o n a l : f u n c t i o n ( A ) { r e t u r n   ! j Q u e r y . v a l i d a t o r . m e t h o d s . r e q u i r e d . c a l l ( t h i s , j Q u e r y . t r i m ( A . v a l u e ) , A ) & & " d e p e n d e n c y - m i s m a t c h " } , s t a r t R e q u e s t : f u n c t i o n ( A ) { i f ( ! t h i s . p e n d i n g [ A . n a m e ] ) { t h i s . p e n d i n g R e q u e s t + + ; t h i s . p e n d i n g [ A . n a m e ] = t r u e } } , s t o p R e q u e s t : f u n c t i o n ( A , B ) { t h i s . p e n d i n g R e q u e s t - - ; i f ( t h i s . p e n d i n g R e q u e s t < 0 ) { t h i s . p e n d i n g R e q u e s t = 0 } d e l e t e   t h i s . p e n d i n g [ A . n a m e ] ; i f ( B & & t h i s . p e n d i n g R e q u e s t = = 0 & & t h i s . f o r m S u b m i t t e d & & t h i s . f o r m ( ) ) { j Q u e r y ( t h i s . c u r r e n t F o r m ) . s u b m i t ( ) } } , p r e v i o u s V a l u e : f u n c t i o n ( A ) { r e t u r n   j Q u e r y . d a t a ( A , " p r e v i o u s V a l u e " ) | | j Q u e r y . d a t a ( A , " p r e v i o u s V a l u e " , p r e v i o u s = { o l d : n u l l , v a l i d : t r u e , m e s s a g e : t h i s . d e f a u l t M e s s a g e ( A , " r e m o t e " ) } ) } } , c l a s s R u l e S e t t i n g s : { r e q u i r e d : { r e q u i r e d : t r u e } , e m a i l : { e m a i l : t r u e } , u r l : { u r l : t r u e } , d a t e : { d a t e : t r u e } , d a t e I S O : { d a t e I S O : t r u e } , d a t e D E : { d a t e D E : t r u e } , n u m b e r : { n u m b e r : t r u e } , n u m b e r D E : { n u m b e r D E : t r u e } , d i g i t s : { d i g i t s : t r u e } , c r e d i t c a r d : { c r e d i t c a r d : t r u e } } , a d d C l a s s R u l e s : f u n c t i o n ( A , B ) { A . c o n s t r u c t o r = = S t r i n g ? t h i s . c l a s s R u l e S e t t i n g s [ A ] = B : j Q u e r y . e x t e n d ( t h i s . c l a s s R u l e S e t t i n g s , A ) } , c l a s s R u l e s : f u n c t i o n ( B ) { v a r   C = { } ; v a r   A = j Q u e r y ( B ) . a t t r ( " c l a s s " ) ; A & & j Q u e r y . e a c h ( A . s p l i t ( "   " ) , f u n c t i o n ( ) { i f ( t h i s   i n   j Q u e r y . v a l i d a t o r . c l a s s R u l e S e t t i n g s ) { j Q u e r y . e x t e n d ( C , j Q u e r y . v a l i d a t o r . c l a s s R u l e S e t t i n g s [ t h i s ] ) } } ) ; r e t u r n   C } , a t t r i b u t e R u l e s : f u n c t i o n ( B ) { v a r   D = { } ; v a r   A = j Q u e r y ( B ) ; f o r ( m e t h o d   i n   j Q u e r y . v a l i d a t o r . m e t h o d s ) { v a r   C = A . a t t r ( m e t h o d ) ; i f ( C ! = = u n d e f i n e d & & C ! = = " " ) { D [ m e t h o d ] = C } } i f ( D . m a x l e n g t h & & / - 1 | 2 1 4 7 4 8 3 6 4 7 | 5 2 4 2 8 8 / . t e s t ( D . m a x l e n g t h ) ) { d e l e t e   D . m a x l e n g t h ; d e l e t e   D . m a x L e n g t h } r e t u r n   D } , m e t a d a t a R u l e s : f u n c t i o n ( A ) { i f ( ! j Q u e r y . m e t a d a t a ) { r e t u r n { } } v a r   B = j Q u e r y . d a t a ( A . f o r m , " v a l i d a t o r " ) . s e t t i n g s . m e t a ; r e t u r n   B ? j Q u e r y ( A ) . m e t a d a t a ( ) [ B ] : j Q u e r y ( A ) . m e t a d a t a ( ) } , s t a t i c R u l e s : f u n c t i o n ( B ) { v a r   C = { } ; v a r   A = j Q u e r y . d a t a ( B . f o r m , " v a l i d a t o r " ) ; i f ( A . s e t t i n g s . r u l e s ) { C = j Q u e r y . v a l i d a t o r . n o r m a l i z e R u l e ( A . s e t t i n g s . r u l e s [ B . n a m e ] ) | | { } } r e t u r n   C } , n o r m a l i z e R u l e s : f u n c t i o n ( B , A ) { j Q u e r y . e a c h ( { m i n L e n g t h : " m i n l e n g t h " , m a x L e n g t h : " m a x l e n g t h " , r a n g e L e n g t h : " r a n g e l e n g t h " , m i n V a l u e : " m i n " , m a x V a l u e : " m a x " , r a n g e V a l u e : " r a n g e " } , f u n c t i o n ( D , C ) { i f ( B [ D ] ) { B [ C ] = B [ D ] ; d e l e t e   B [ D ] } } ) ; $ . e a c h ( B , f u n c t i o n ( E , D ) { i f ( D = = = f a l s e ) { d e l e t e   B [ E ] ; r e t u r n   } i f ( D . p a r a m | | D . d e p e n d s ) { v a r   C = t r u e ; s w i t c h ( t y p e o f   D . d e p e n d s ) { c a s e " s t r i n g " : C = ! ! j Q u e r y ( D . d e p e n d s , A . f o r m ) . l e n g t h ; b r e a k ; c a s e " f u n c t i o n " : C = D . d e p e n d s . c a l l ( A , A ) ; b r e a k } i f ( C ) { B [ E ] = D . p a r a m ! = = u n d e f i n e d ? D . p a r a m : t r u e } e l s e { d e l e t e   B [ E ] } } } ) ; j Q u e r y . e a c h ( B , f u n c t i o n ( C , D ) { B [ C ] = j Q u e r y . i s F u n c t i o n ( D ) ? D ( A ) : D } ) ; j Q u e r y . e a c h ( [ " m i n l e n g t h " , " m a x l e n g t h " , " m i n " , " m a x " ] , f u n c t i o n ( ) { i f ( B [ t h i s ] ) { B [ t h i s ] = N u m b e r ( B [ t h i s ] ) } } ) ; j Q u e r y . e a c h ( [ " r a n g e l e n g t h " , " r a n g e " ] , f u n c t i o n ( ) { i f ( B [ t h i s ] ) { B [ t h i s ] = [ N u m b e r ( B [ t h i s ] [ 0 ] ) , N u m b e r ( B [ t h i s ] [ 1 ] ) ] } } ) ; i f ( j Q u e r y . v a l i d a t o r . a u t o C r e a t e R a n g e s ) { i f ( B . m i n & & B . m a x ) { B . r a n g e = [ B . m i n , B . m a x ] ; d e l e t e   B . m i n ; d e l e t e   B . m a x } i f ( B . m i n l e n g t h & & B . m a x l e n g t h ) { B . r a n g e l e n g t h = [ B . m i n l e n g t h , B . m a x l e n g t h ] ; d e l e t e   B . m i n l e n g t h ; d e l e t e   B . m a x l e n g t h } } r e t u r n   B } , n o r m a l i z e R u l e : f u n c t i o n ( B ) { i f ( t y p e o f   B = = " s t r i n g " ) { v a r   A = { } ; j Q u e r y . e a c h ( B . s p l i t ( / \ s / ) , f u n c t i o n ( ) { A [ t h i s ] = t r u e } ) ; B = A } r e t u r n   B } , a d d M e t h o d : f u n c t i o n ( A , C , B ) { j Q u e r y . v a l i d a t o r . m e t h o d s [ A ] = C ; j Q u e r y . v a l i d a t o r . m e s s a g e s [ A ] = B ; i f ( C . l e n g t h < 3 ) { j Q u e r y . v a l i d a t o r . a d d C l a s s R u l e s ( A , j Q u e r y . v a l i d a t o r . n o r m a l i z e R u l e ( A ) ) } } , m e t h o d s : { r e q u i r e d : f u n c t i o n ( C , B , D ) { i f ( ! t h i s . d e p e n d ( D , B ) ) { r e t u r n " d e p e n d e n c y - m i s m a t c h " } s w i t c h ( B . n o d e N a m e . t o L o w e r C a s e ( ) ) { c a s e " s e l e c t " : v a r   A = j Q u e r y ( " o p t i o n : s e l e c t e d " , B ) ; r e t u r n   A . l e n g t h > 0 & & ( B . t y p e = = " s e l e c t - m u l t i p l e " | | ( j Q u e r y . b r o w s e r . m s i e & & ! ( A [ 0 ] . a t t r i b u t e s . v a l u e . s p e c i f i e d ) ? A [ 0 ] . t e x t : A [ 0 ] . v a l u e ) . l e n g t h > 0 ) ; c a s e " i n p u t " : i f ( t h i s . c h e c k a b l e ( B ) ) { r e t u r n   t h i s . g e t L e n g t h ( C , B ) > 0 } d e f a u l t : r e t u r n   C . l e n g t h > 0 } } , r e m o t e : f u n c t i o n ( E , B , F ) { i f ( t h i s . o p t i o n a l ( B ) ) { r e t u r n " d e p e n d e n c y - m i s m a t c h " } v a r   C = t h i s . p r e v i o u s V a l u e ( B ) ; i f ( ! t h i s . s e t t i n g s . m e s s a g e s [ B . n a m e ] ) { t h i s . s e t t i n g s . m e s s a g e s [ B . n a m e ] = { } } t h i s . s e t t i n g s . m e s s a g e s [ B . n a m e ] . r e m o t e = t y p e o f   C . m e s s a g e = = " f u n c t i o n " ? C . m e s s a g e ( E ) : C . m e s s a g e ; i f ( C . o l d ! = = E ) { C . o l d = E ; v a r   A = t h i s ; t h i s . s t a r t R e q u e s t ( B ) ; v a r   D = { } ; D [ B . n a m e ] = E ; j Q u e r y . a j a x ( { u r l : F , m o d e : " a b o r t " , p o r t : " v a l i d a t e " + B . n a m e , d a t a T y p e : " j s o n " , d a t a : D , s u c c e s s : f u n c t i o n ( H ) { i f ( ! H ) { v a r   I = { } ; I [ B . n a m e ] = H | | A . d e f a u l t M e s s a g e ( B , " r e m o t e " ) ; A . s h o w E r r o r s ( I ) } e l s e { v a r   G = A . f o r m S u b m i t t e d ; A . p r e p a r e E l e m e n t ( B ) ; A . f o r m S u b m i t t e d = G ; A . s u c c e s s L i s t . p u s h ( B ) ; A . s h o w E r r o r s ( ) } C . v a l i d = H ; A . s t o p R e q u e s t ( B , H ) } } ) ; r e t u r n " p e n d i n g " } e l s e { i f ( t h i s . p e n d i n g [ B . n a m e ] ) { r e t u r n " p e n d i n g " } } r e t u r n   C . v a l i d } , m i n l e n g t h : f u n c t i o n ( B , A , C ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | t h i s . g e t L e n g t h ( B , A ) > = C } , m i n L e n g t h : f u n c t i o n ( B , A , C ) { r e t u r n   j Q u e r y . v a l i d a t o r . m e t h o d s . m i n l e n g t h . a p p l y ( t h i s , a r g u m e n t s ) } , m a x l e n g t h : f u n c t i o n ( B , A , C ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | t h i s . g e t L e n g t h ( B , A ) < = C } , m a x L e n g t h : f u n c t i o n ( B , A , C ) { r e t u r n   j Q u e r y . v a l i d a t o r . m e t h o d s . m a x l e n g t h . a p p l y ( t h i s , a r g u m e n t s ) } , r a n g e l e n g t h : f u n c t i o n ( C , A , D ) { v a r   B = t h i s . g e t L e n g t h ( C , A ) ; r e t u r n   t h i s . o p t i o n a l ( A ) | | ( B > = D [ 0 ] & & B < = D [ 1 ] ) } , r a n g e L e n g t h : f u n c t i o n ( B , A , C ) { r e t u r n   j Q u e r y . v a l i d a t o r . m e t h o d s . r a n g e l e n g t h . a p p l y ( t h i s , a r g u m e n t s ) } , m i n : f u n c t i o n ( B , A , C ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | B > = C } , m i n V a l u e : f u n c t i o n ( ) { r e t u r n   j Q u e r y . v a l i d a t o r . m e t h o d s . m i n . a p p l y ( t h i s , a r g u m e n t s ) } , m a x : f u n c t i o n ( B , A , C ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | B < = C } , m a x V a l u e : f u n c t i o n ( ) { r e t u r n   j Q u e r y . v a l i d a t o r . m e t h o d s . m a x . a p p l y ( t h i s , a r g u m e n t s ) } , r a n g e : f u n c t i o n ( B , A , C ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | ( B > = C [ 0 ] & & B < = C [ 1 ] ) } , r a n g e V a l u e : f u n c t i o n ( ) { r e t u r n   j Q u e r y . v a l i d a t o r . m e t h o d s . r a n g e . a p p l y ( t h i s , a r g u m e n t s ) } , e m a i l : f u n c t i o n ( B , A ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | / ^ ( ( ( [ a - z ] | \ d | [ ! # \ $ % & ' \ * \ + \ - \ / = \ ? \ ^ _ ` { \ | } ~ ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) + ( \ . ( [ a - z ] | \ d | [ ! # \ $ % & ' \ * \ + \ - \ / = \ ? \ ^ _ ` { \ | } ~ ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) + ) * ) | ( ( \ x 2 2 ) ( ( ( ( \ x 2 0 | \ x 0 9 ) * ( \ x 0 d \ x 0 a ) ) ? ( \ x 2 0 | \ x 0 9 ) + ) ? ( ( [ \ x 0 1 - \ x 0 8 \ x 0 b \ x 0 c \ x 0 e - \ x 1 f \ x 7 f ] | \ x 2 1 | [ \ x 2 3 - \ x 5 b ] | [ \ x 5 d - \ x 7 e ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( \ \ ( [ \ x 0 1 - \ x 0 9 \ x 0 b \ x 0 c \ x 0 d - \ x 7 f ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) ) ) ) * ( ( ( \ x 2 0 | \ x 0 9 ) * ( \ x 0 d \ x 0 a ) ) ? ( \ x 2 0 | \ x 0 9 ) + ) ? ( \ x 2 2 ) ) ) @ ( ( ( [ a - z ] | \ d | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( ( [ a - z ] | \ d | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) ( [ a - z ] | \ d | - | \ . | _ | ~ | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) * ( [ a - z ] | \ d | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) ) ) \ . ) + ( ( [ a - z ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( ( [ a - z ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) ( [ a - z ] | \ d | - | \ . | _ | ~ | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) * ( [ a - z ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) ) ) \ . ? $ / i . t e s t ( A . v a l u e ) } , u r l : f u n c t i o n ( B , A ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | / ^ ( h t t p s ? | f t p ) : \ / \ / ( ( ( ( [ a - z ] | \ d | - | \ . | _ | ~ | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( % [ \ d a - f ] { 2 } ) | [ ! \ $ & ' \ ( \ ) \ * \ + , ; = ] | : ) * @ ) ? ( ( ( \ d | [ 1 - 9 ] \ d | 1 \ d \ d | 2 [ 0 - 4 ] \ d | 2 5 [ 0 - 5 ] ) \ . ( \ d | [ 1 - 9 ] \ d | 1 \ d \ d | 2 [ 0 - 4 ] \ d | 2 5 [ 0 - 5 ] ) \ . ( \ d | [ 1 - 9 ] \ d | 1 \ d \ d | 2 [ 0 - 4 ] \ d | 2 5 [ 0 - 5 ] ) \ . ( \ d | [ 1 - 9 ] \ d | 1 \ d \ d | 2 [ 0 - 4 ] \ d | 2 5 [ 0 - 5 ] ) ) | ( ( ( [ a - z ] | \ d | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( ( [ a - z ] | \ d | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) ( [ a - z ] | \ d | - | \ . | _ | ~ | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) * ( [ a - z ] | \ d | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) ) ) \ . ) + ( ( [ a - z ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( ( [ a - z ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) ( [ a - z ] | \ d | - | \ . | _ | ~ | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) * ( [ a - z ] | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) ) ) \ . ? ) ( : \ d * ) ? ) ( \ / ( ( ( [ a - z ] | \ d | - | \ . | _ | ~ | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( % [ \ d a - f ] { 2 } ) | [ ! \ $ & ' \ ( \ ) \ * \ + , ; = ] | : | @ ) + ( \ / ( ( [ a - z ] | \ d | - | \ . | _ | ~ | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( % [ \ d a - f ] { 2 } ) | [ ! \ $ & ' \ ( \ ) \ * \ + , ; = ] | : | @ ) * ) * ) ? ) ? ( \ ? ( ( ( [ a - z ] | \ d | - | \ . | _ | ~ | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( % [ \ d a - f ] { 2 } ) | [ ! \ $ & ' \ ( \ ) \ * \ + , ; = ] | : | @ ) | [ \ u E 0 0 0 - \ u F 8 F F ] | \ / | \ ? ) * ) ? ( \ # ( ( ( [ a - z ] | \ d | - | \ . | _ | ~ | [ \ u 0 0 A 0 - \ u D 7 F F \ u F 9 0 0 - \ u F D C F \ u F D F 0 - \ u F F E F ] ) | ( % [ \ d a - f ] { 2 } ) | [ ! \ $ & ' \ ( \ ) \ * \ + , ; = ] | : | @ ) | \ / | \ ? ) * ) ? $ / i . t e s t ( A . v a l u e ) } , d a t e : f u n c t i o n ( B , A ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | ! / I n v a l i d | N a N / . t e s t ( n e w   D a t e ( B ) ) } , d a t e I S O : f u n c t i o n ( B , A ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | / ^ \ d { 4 } [ \ / - ] \ d { 1 , 2 } [ \ / - ] \ d { 1 , 2 } $ / . t e s t ( B ) } , d a t e D E : f u n c t i o n ( B , A ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | / ^ \ d \ d ? \ . \ d \ d ? \ . \ d \ d \ d ? \ d ? $ / . t e s t ( B ) } , n u m b e r : f u n c t i o n ( B , A ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | / ^ - ? ( ? : \ d + | \ d { 1 , 3 } ( ? : , \ d { 3 } ) + ) ( ? : \ . \ d + ) ? $ / . t e s t ( B ) } , n u m b e r D E : f u n c t i o n ( B , A ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | / ^ - ? ( ? : \ d + | \ d { 1 , 3 } ( ? : \ . \ d { 3 } ) + ) ( ? : , \ d + ) ? $ / . t e s t ( B ) } , d i g i t s : f u n c t i o n ( B , A ) { r e t u r n   t h i s . o p t i o n a l ( A ) | | / ^ \ d + $ / . t e s t ( B ) } , c r e d i t c a r d : f u n c t i o n ( E , B ) { i f ( t h i s . o p t i o n a l ( B ) ) { r e t u r n " d e p e n d e n c y - m i s m a t c h " } i f ( / [ ^ 0 - 9 - ] + / . t e s t ( E ) ) { r e t u r n   f a l s e } v a r   F = 0 , D = 0 , A = f a l s e ; E = E . r e p l a c e ( / \ D / g , " " ) ; f o r ( n = E . l e n g t h - 1 ; n > = 0 ; n - - ) { v a r   C = E . c h a r A t ( n ) ; v a r   D = p a r s e I n t ( C , 1 0 ) ; i f ( A ) { i f ( ( D * = 2 ) > 9 ) { D - = 9 } } F + = D ; A = ! A } r e t u r n ( F % 1 0 ) = = 0 } , a c c e p t : f u n c t i o n ( B , A , C ) { C = t y p e o f   C = = " s t r i n g " ? C : " p n g | j p e ? g | g i f " ; r e t u r n   t h i s . o p t i o n a l ( A ) | | B . m a t c h ( n e w   R e g E x p ( " . ( " + C + " ) $ " , " i " ) ) } , e q u a l T o : f u n c t i o n ( B , A , C ) { r e t u r n   B = = j Q u e r y ( C ) . v a l ( ) } } } ) ; ( f u n c t i o n ( C ) { v a r   B = C . a j a x ; v a r   A = { } ; C . a j a x = f u n c t i o n ( E ) { E = j Q u e r y . e x t e n d ( E , j Q u e r y . e x t e n d ( { } , j Q u e r y . a j a x S e t t i n g s , E ) ) ; v a r   D = E . p o r t ; i f ( E . m o d e = = " a b o r t " ) { i f ( A [ D ] ) { A [ D ] . a b o r t ( ) } r e t u r n ( A [ D ] = B . a p p l y ( t h i s , a r g u m e n t s ) ) } r e t u r n   B . a p p l y ( t h i s , a r g u m e n t s ) } } ) ( j Q u e r y ) ; ( f u n c t i o n ( A ) { A . e a c h ( { f o c u s : " f o c u s i n " , b l u r : " f o c u s o u t " } , f u n c t i o n ( C , B ) { A . e v e n t . s p e c i a l [ B ] = { s e t u p : f u n c t i o n ( ) { i f ( A . b r o w s e r . m s i e ) { r e t u r n   f a l s e } t h i s . a d d E v e n t L i s t e n e r ( C , A . e v e n t . s p e c i a l [ B ] . h a n d l e r , t r u e ) } , t e a r d o w n : f u n c t i o n ( ) { i f ( A . b r o w s e r . m s i e ) { r e t u r n   f a l s e } t h i s . r e m o v e E v e n t L i s t e n e r ( C , A . e v e n t . s p e c i a l [ B ] . h a n d l e r , t r u e ) } , h a n d l e r : f u n c t i o n ( D ) { a r g u m e n t s [ 0 ] = A . e v e n t . f i x ( D ) ; a r g u m e n t s [ 0 ] . t y p e = B ; r e t u r n   A . e v e n t . h a n d l e . a p p l y ( t h i s , a r g u m e n t s ) } } } ) ; A . e x t e n d ( A . f n , { d e l e g a t e : f u n c t i o n ( D , C , B ) { r e t u r n   t h i s . b i n d ( D , f u n c t i o n ( E ) { v a r   F = A ( E . t a r g e t ) ; i f ( F . i s ( C ) ) { r e t u r n   B . a p p l y ( F , a r g u m e n t s ) } } ) } , t r i g g e r E v e n t : f u n c t i o n ( B , C ) { r e t u r n   t h i s . t r i g g e r H a n d l e r ( B , [ j Q u e r y . e v e n t . f i x ( { t y p e : B , t a r g e t : C } ) ] ) } } ) } ) ( j Q u e r y ) ; ( f u n c t i o n ( E ) { E . f n . j q m = f u n c t i o n ( A ) { v a r   F = { z I n d e x : 3 0 0 0 , o v e r l a y : 5 0 , o v e r l a y C l a s s : " j q m O v e r l a y " , c l o s e C l a s s : " j q m C l o s e " , t r i g g e r : " . j q M o d a l " , a j a x : f a l s e , t a r g e t : f a l s e , m o d a l : f a l s e , t o T o p : f a l s e , o n S h o w : f a l s e , o n H i d e : f a l s e , o n L o a d : f a l s e } ; r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { i f ( t h i s . _ j q m ) { r e t u r n   } N + + ; t h i s . _ j q m = N ; L [ N ] = { c : E . e x t e n d ( F , A ) , a : f a l s e , w : E ( t h i s ) . a d d C l a s s ( " j q m I D " + N ) , s : N } ; F . t r i g g e r & & E ( t h i s ) . j q m A d d T r i g g e r ( F . t r i g g e r ) } ) } ; E . f n . j q m A d d C l o s e = f u n c t i o n ( A ) { r e t u r n   C ( t h i s , A , " j q m H i d e " ) } ; E . f n . j q m A d d T r i g g e r = f u n c t i o n ( A ) { r e t u r n   C ( t h i s , A , " j q m S h o w " ) } ; E . f n . j q m S h o w = f u n c t i o n ( A ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { ! L [ t h i s . _ j q m ] . a & & E . j q m . o p e n ( t h i s . _ j q m , A ) } ) } ; E . f n . j q m H i d e = f u n c t i o n ( A ) { r e t u r n   t h i s . e a c h ( f u n c t i o n ( ) { L [ t h i s . _ j q m ] . a & & E . j q m . c l o s e ( t h i s . _ j q m , A ) } ) } ; E . j q m = { h a s h : { } , o p e n : f u n c t i o n ( U , T ) { v a r   O = L [ U ] , P = O . c , H = " . " + P . c l o s e C l a s s , Q = / ^ \ d + $ / . t e s t ( O . w . c s s ( " z - i n d e x " ) ) & & O . w . c s s ( " z - i n d e x " ) | | P . z I n d e x , F = E ( " < d i v > < / d i v > " ) . c s s ( { h e i g h t : ( D ? E ( d o c u m e n t . b o d y ) . h e i g h t ( ) : E ( d o c u m e n t ) . h e i g h t ( ) ) + " p x " , w i d t h : " 1 0 0 % " , p o s i t i o n : " a b s o l u t e " , l e f t : 0 , t o p : 0 , b o t t o m : 0 , " z - i n d e x " : Q - 1 , o p a c i t y : P . o v e r l a y / 1 0 0 } ) ; O . t = T ; O . a = t r u e ; O . w . c s s ( " z - i n d e x " , Q ) ; i f ( P . m o d a l ) { ! B [ 0 ] & & M ( " b i n d " ) ; B . p u s h ( U ) ; F . c s s ( " c u r s o r " , " w a i t " ) } e l s e { i f ( P . o v e r l a y > 0 ) { O . w . j q m A d d C l o s e ( F ) } e l s e { F = f a l s e } } O . o = ( F ) ? F . a d d C l a s s ( P . o v e r l a y C l a s s ) . p r e p e n d T o ( " b o d y " ) : f a l s e ; i f ( D & & E ( " h t m l , b o d y " ) . c s s ( { h e i g h t : " 1 0 0 % " , w i d t h : " 1 0 0 % " } ) & & F ) { F = F . c s s ( { p o s i t i o n : " a b s o l u t e " } ) [ 0 ] ; f o r ( v a r   R   i n   { T o p : 1 , L e f t : 1 } ) { F . s t y l e . s e t E x p r e s s i o n ( R . t o L o w e r C a s e ( ) , " ( _ = ( d o c u m e n t . d o c u m e n t E l e m e n t . s c r o l l " + R + "   | |   d o c u m e n t . b o d y . s c r o l l " + R + " ) ) + ' p x ' " ) } } i f ( T & & T . a j a x ) { P . a j a x = T . a j a x } i f ( P . a j a x ) { v a r   A = P . t a r g e t | | O . w , S = P . a j a x , A = ( t y p e o f   A = = " s t r i n g " ) ? E ( A , O . w ) : E ( A ) , S = ( S . s u b s t r ( 0 , 1 ) = = " @ " ) ? E ( T ) . a t t r ( S . s u b s t r i n g ( 1 ) ) : S ; A . l o a d ( S , f u n c t i o n ( ) { P . o n L o a d & & P . o n L o a d . c a l l ( t h i s , O ) ; H & & O . w . j q m A d d C l o s e ( E ( H , O . w ) ) ; I ( O ) } ) } e l s e { H & & O . w . j q m A d d C l o s e ( E ( H , O . w ) ) } P . t o T o p & & O . o & & O . w . b e f o r e ( ' < s p a n   i d = " j q m P ' + O . w [ 0 ] . _ j q m + ' " > < / s p a n > ' ) . i n s e r t A f t e r ( O . o ) ; P . o n S h o w & & P . o n S h o w ( O ) ; O . w . s h o w ( ) ; I ( O ) ; r e t u r n   f a l s e } , c l o s e : f u n c t i o n ( F ) { v a r   A = L [ F ] ; A . a = f a l s e ; i f ( A . c . m o d a l ) { B . p o p ( ) ; ! B [ 0 ] & & M ( " u n b i n d " ) } A . c . t o T o p & & A . o & & E ( " # j q m P " + A . w [ 0 ] . _ j q m ) . a f t e r ( A . w ) . r e m o v e ( ) ; i f ( A . c . o n H i d e ) { A . c . o n H i d e ( A ) } e l s e { A . w . h i d e ( ) & & A . o & & A . o . r e m o v e ( ) } r e t u r n   f a l s e } } ; v a r   N = 0 , L = E . j q m . h a s h , B = [ ] , D = E . b r o w s e r . m s i e & & ( E . b r o w s e r . v e r s i o n = = " 6 . 0 " ) , G = E ( ' < i f r a m e   s r c = " j a v a s c r i p t : f a l s e ; d o c u m e n t . w r i t e ( \ ' \ ' ) ; "   c l a s s = " j q m " > < / i f r a m e > ' ) . c s s ( { o p a c i t y : 0 } ) , I = f u n c t i o n ( A ) { i f ( D ) { A . o & & A . o . h t m l ( ' < p   s t y l e = " w i d t h : 1 0 0 % ; h e i g h t : 1 0 0 % " / > ' ) . p r e p e n d ( G ) | | ( ! E ( " i f r a m e . j q m " , A . w ) [ 0 ] & & A . w . p r e p e n d ( G ) ) } J ( A ) } , J = f u n c t i o n ( A ) { t r y { E ( " : i n p u t : v i s i b l e " , A . w ) [ 0 ] . f o c u s ( ) } c a t c h ( F ) { } } , M = f u n c t i o n ( A ) { E ( ) [ A ] ( " k e y p r e s s " , K ) [ A ] ( " k e y d o w n " , K ) [ A ] ( " m o u s e d o w n " , K ) } , K = f u n c t i o n ( H ) { v a r   A = L [ B [ B . l e n g t h - 1 ] ] , F = ( ! E ( H . t a r g e t ) . p a r e n t s ( " . j q m I D " + A . s ) [ 0 ] ) ; F & & J ( A ) ; r e t u r n   ! F } , C = f u n c t i o n ( A , H , O ) { v a r   F = [ ] ; A . e a c h ( f u n c t i o n ( ) { F . p u s h ( t h i s . _ j q m ) } ) ; E ( H ) . e a c h ( f u n c t i o n ( ) { i f ( t h i s [ O ] ) { E . e x t e n d ( t h i s [ O ] , F ) } e l s e { t h i s [ O ] = F ; E ( t h i s ) . c l i c k ( f u n c t i o n ( ) { f o r ( v a r   P   i n   { j q m S h o w : 1 , j q m H i d e : 1 } ) { f o r ( v a r   Q   i n   t h i s [ P ] ) { i f ( L [ t h i s [ P ] [ Q ] ] ) { L [ t h i s [ P ] [ Q ] ] . w [ P ] ( t h i s ) } } } r e t u r n   f a l s e } ) } } ) ; r e t u r n   A } } ) ( j Q u e r y ) ; v a r   S W F U p l o a d ; i f ( S W F U p l o a d = = u n d e f i n e d ) { S W F U p l o a d = f u n c t i o n ( A ) { t h i s . i n i t S W F U p l o a d ( A ) } } S W F U p l o a d . p r o t o t y p e . i n i t S W F U p l o a d = f u n c t i o n ( B ) { t r y { t h i s . c u s t o m S e t t i n g s = { } ; t h i s . s e t t i n g s = B ; t h i s . e v e n t Q u e u e = [ ] ; t h i s . m o v i e N a m e = " S W F U p l o a d _ " + S W F U p l o a d . m o v i e C o u n t + + ; t h i s . m o v i e E l e m e n t = n u l l ; S W F U p l o a d . i n s t a n c e s [ t h i s . m o v i e N a m e ] = t h i s ; t h i s . i n i t S e t t i n g s ( ) ; t h i s . l o a d F l a s h ( ) ; t h i s . d i s p l a y D e b u g I n f o ( ) } c a t c h ( A ) { d e l e t e   S W F U p l o a d . i n s t a n c e s [ t h i s . m o v i e N a m e ] ; t h r o w   A } } ; S W F U p l o a d . i n s t a n c e s = { } ; S W F U p l o a d . m o v i e C o u n t = 0 ; S W F U p l o a d . v e r s i o n = " 2 . 2 . 0   B e t a   5   2 0 0 8 - 0 1 - 2 9 " ; S W F U p l o a d . Q U E U E _ E R R O R = { Q U E U E _ L I M I T _ E X C E E D E D : - 1 0 0 , F I L E _ E X C E E D S _ S I Z E _ L I M I T : - 1 1 0 , Z E R O _ B Y T E _ F I L E : - 1 2 0 , I N V A L I D _ F I L E T Y P E : - 1 3 0 } ; S W F U p l o a d . U P L O A D _ E R R O R = { H T T P _ E R R O R : - 2 0 0 , M I S S I N G _ U P L O A D _ U R L : - 2 1 0 , I O _ E R R O R : - 2 2 0 , S E C U R I T Y _ E R R O R : - 2 3 0 , U P L O A D _ L I M I T _ E X C E E D E D : - 2 4 0 , U P L O A D _ F A I L E D : - 2 5 0 , S P E C I F I E D _ F I L E _ I D _ N O T _ F O U N D : - 2 6 0 , F I L E _ V A L I D A T I O N _ F A I L E D : - 2 7 0 , F I L E _ C A N C E L L E D : - 2 8 0 , U P L O A D _ S T O P P E D : - 2 9 0 } ; S W F U p l o a d . F I L E _ S T A T U S = { Q U E U E D : - 1 , I N _ P R O G R E S S : - 2 , E R R O R : - 3 , C O M P L E T E : - 4 , C A N C E L L E D : - 5 } ; S W F U p l o a d . B U T T O N _ A C T I O N = { S E L E C T _ F I L E : - 1 0 0 , S E L E C T _ F I L E S : - 1 1 0 , S T A R T _ U P L O A D : - 1 2 0 } ; S W F U p l o a d . C U R S O R = { A R R O W : - 1 , H A N D : - 2 } ; S W F U p l o a d . W I N D O W _ M O D E = { W I N D O W : " w i n d o w " , T R A N S P A R E N T : " t r a n s p a r e n t " , O P A Q U E : " o p a q u e " } ; S W F U p l o a d . p r o t o t y p e . i n i t S e t t i n g s = f u n c t i o n ( ) { t h i s . e n s u r e D e f a u l t = f u n c t i o n ( B , A ) { t h i s . s e t t i n g s [ B ] = ( t h i s . s e t t i n g s [ B ] = = u n d e f i n e d ) ? A : t h i s . s e t t i n g s [ B ] } ; t h i s . e n s u r e D e f a u l t ( " u p l o a d _ u r l " , " " ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ p o s t _ n a m e " , " F i l e d a t a " ) ; t h i s . e n s u r e D e f a u l t ( " p o s t _ p a r a m s " , { } ) ; t h i s . e n s u r e D e f a u l t ( " u s e _ q u e r y _ s t r i n g " , f a l s e ) ; t h i s . e n s u r e D e f a u l t ( " r e q u e u e _ o n _ e r r o r " , f a l s e ) ; t h i s . e n s u r e D e f a u l t ( " h t t p _ s u c c e s s " , [ ] ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ t y p e s " , " * . * " ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ t y p e s _ d e s c r i p t i o n " , " A l l   F i l e s " ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ s i z e _ l i m i t " , 0 ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ u p l o a d _ l i m i t " , 0 ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ q u e u e _ l i m i t " , 0 ) ; t h i s . e n s u r e D e f a u l t ( " f l a s h _ u r l " , " s w f u p l o a d . s w f " ) ; t h i s . e n s u r e D e f a u l t ( " p r e v e n t _ s w f _ c a c h i n g " , t r u e ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ i m a g e _ u r l " , " " ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ w i d t h " , 1 ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ h e i g h t " , 1 ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ t e x t " , " " ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ t e x t _ s t y l e " , " c o l o r :   # 0 0 0 0 0 0 ;   f o n t - s i z e :   1 6 p t ; " ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ t e x t _ t o p _ p a d d i n g " , 0 ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ t e x t _ l e f t _ p a d d i n g " , 0 ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ a c t i o n " , S W F U p l o a d . B U T T O N _ A C T I O N . S E L E C T _ F I L E S ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ d i s a b l e d " , f a l s e ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ p l a c e h o l d e r _ i d " , " " ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ c u r s o r " , S W F U p l o a d . C U R S O R . A R R O W ) ; t h i s . e n s u r e D e f a u l t ( " b u t t o n _ w i n d o w _ m o d e " , S W F U p l o a d . W I N D O W _ M O D E . W I N D O W ) ; t h i s . e n s u r e D e f a u l t ( " d e b u g " , f a l s e ) ; t h i s . s e t t i n g s . d e b u g _ e n a b l e d = t h i s . s e t t i n g s . d e b u g ; t h i s . s e t t i n g s . r e t u r n _ u p l o a d _ s t a r t _ h a n d l e r = t h i s . r e t u r n U p l o a d S t a r t ; t h i s . e n s u r e D e f a u l t ( " s w f u p l o a d _ l o a d e d _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ d i a l o g _ s t a r t _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ q u e u e d _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ q u e u e _ e r r o r _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " f i l e _ d i a l o g _ c o m p l e t e _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " u p l o a d _ s t a r t _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " u p l o a d _ p r o g r e s s _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " u p l o a d _ e r r o r _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " u p l o a d _ s u c c e s s _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " u p l o a d _ c o m p l e t e _ h a n d l e r " , n u l l ) ; t h i s . e n s u r e D e f a u l t ( " d e b u g _ h a n d l e r " , t h i s . d e b u g M e s s a g e ) ; t h i s . e n s u r e D e f a u l t ( " c u s t o m _ s e t t i n g s " , { } ) ; t h i s . c u s t o m S e t t i n g s = t h i s . s e t t i n g s . c u s t o m _ s e t t i n g s ; i f ( ! ! t h i s . s e t t i n g s . p r e v e n t _ s w f _ c a c h i n g ) { t h i s . s e t t i n g s . f l a s h _ u r l = t h i s . s e t t i n g s . f l a s h _ u r l + ( t h i s . s e t t i n g s . f l a s h _ u r l . i n d e x O f ( " ? " ) < 0 ? " ? " : " & " ) + " p r e v e n t s w f c a c h i n g = " + n e w   D a t e ( ) . g e t T i m e ( ) } d e l e t e   t h i s . e n s u r e D e f a u l t } ; S W F U p l o a d . p r o t o t y p e . l o a d F l a s h = f u n c t i o n ( ) { v a r   A , B ; i f ( d o c u m e n t . g e t E l e m e n t B y I d ( t h i s . m o v i e N a m e ) ! = = n u l l ) { t h r o w " I D   " + t h i s . m o v i e N a m e + "   i s   a l r e a d y   i n   u s e .   T h e   F l a s h   O b j e c t   c o u l d   n o t   b e   a d d e d " } A = d o c u m e n t . g e t E l e m e n t B y I d ( t h i s . s e t t i n g s . b u t t o n _ p l a c e h o l d e r _ i d ) ; i f ( A = = u n d e f i n e d ) { t h r o w " C o u l d   n o t   f i n d   t h e   p l a c e h o l d e r   e l e m e n t :   " + t h i s . s e t t i n g s . b u t t o n _ p l a c e h o l d e r _ i d } B = d o c u m e n t . c r e a t e E l e m e n t ( " d i v " ) ; B . i n n e r H T M L = t h i s . g e t F l a s h H T M L ( ) ; A . p a r e n t N o d e . r e p l a c e C h i l d ( B . f i r s t C h i l d , A ) ; i f ( w i n d o w [ t h i s . m o v i e N a m e ] = = u n d e f i n e d ) { w i n d o w [ t h i s . m o v i e N a m e ] = t h i s . g e t M o v i e E l e m e n t ( ) } } ; S W F U p l o a d . p r o t o t y p e . g e t F l a s h H T M L = f u n c t i o n ( ) { r e t u r n [ ' < o b j e c t   i d = " ' , t h i s . m o v i e N a m e , ' "   t y p e = " a p p l i c a t i o n / x - s h o c k w a v e - f l a s h "   d a t a = " ' , t h i s . s e t t i n g s . f l a s h _ u r l , ' "   w i d t h = " ' , t h i s . s e t t i n g s . b u t t o n _ w i d t h , ' "   h e i g h t = " ' , t h i s . s e t t i n g s . b u t t o n _ h e i g h t , ' "   c l a s s = " s w f u p l o a d " > ' , ' < p a r a m   n a m e = " w m o d e "   v a l u e = " ' , t h i s . s e t t i n g s . b u t t o n _ w i n d o w _ m o d e , ' "   / > ' , ' < p a r a m   n a m e = " m o v i e "   v a l u e = " ' , t h i s . s e t t i n g s . f l a s h _ u r l , ' "   / > ' , ' < p a r a m   n a m e = " q u a l i t y "   v a l u e = " h i g h "   / > ' , ' < p a r a m   n a m e = " m e n u "   v a l u e = " f a l s e "   / > ' , ' < p a r a m   n a m e = " a l l o w S c r i p t A c c e s s "   v a l u e = " a l w a y s "   / > ' , ' < p a r a m   n a m e = " f l a s h v a r s "   v a l u e = " ' + t h i s . g e t F l a s h V a r s ( ) + ' "   / > ' , " < / o b j e c t > " ] . j o i n ( " " ) } ; S W F U p l o a d . p r o t o t y p e . g e t F l a s h V a r s = f u n c t i o n ( ) { v a r   B = t h i s . b u i l d P a r a m S t r i n g ( ) ; v a r   A = t h i s . s e t t i n g s . h t t p _ s u c c e s s . j o i n ( " , " ) ; r e t u r n [ " m o v i e N a m e = " , e n c o d e U R I C o m p o n e n t ( t h i s . m o v i e N a m e ) , " & a m p ; u p l o a d U R L = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . u p l o a d _ u r l ) , " & a m p ; u s e Q u e r y S t r i n g = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . u s e _ q u e r y _ s t r i n g ) , " & a m p ; r e q u e u e O n E r r o r = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . r e q u e u e _ o n _ e r r o r ) , " & a m p ; h t t p S u c c e s s = " , e n c o d e U R I C o m p o n e n t ( A ) , " & a m p ; p a r a m s = " , e n c o d e U R I C o m p o n e n t ( B ) , " & a m p ; f i l e P o s t N a m e = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . f i l e _ p o s t _ n a m e ) , " & a m p ; f i l e T y p e s = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . f i l e _ t y p e s ) , " & a m p ; f i l e T y p e s D e s c r i p t i o n = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . f i l e _ t y p e s _ d e s c r i p t i o n ) , " & a m p ; f i l e S i z e L i m i t = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . f i l e _ s i z e _ l i m i t ) , " & a m p ; f i l e U p l o a d L i m i t = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . f i l e _ u p l o a d _ l i m i t ) , " & a m p ; f i l e Q u e u e L i m i t = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . f i l e _ q u e u e _ l i m i t ) , " & a m p ; d e b u g E n a b l e d = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . d e b u g _ e n a b l e d ) , " & a m p ; b u t t o n I m a g e U R L = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ i m a g e _ u r l ) , " & a m p ; b u t t o n W i d t h = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ w i d t h ) , " & a m p ; b u t t o n H e i g h t = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ h e i g h t ) , " & a m p ; b u t t o n T e x t = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ t e x t ) , " & a m p ; b u t t o n T e x t T o p P a d d i n g = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ t e x t _ t o p _ p a d d i n g ) , " & a m p ; b u t t o n T e x t L e f t P a d d i n g = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ t e x t _ l e f t _ p a d d i n g ) , " & a m p ; b u t t o n T e x t S t y l e = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ t e x t _ s t y l e ) , " & a m p ; b u t t o n A c t i o n = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ a c t i o n ) , " & a m p ; b u t t o n D i s a b l e d = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ d i s a b l e d ) , " & a m p ; b u t t o n C u r s o r = " , e n c o d e U R I C o m p o n e n t ( t h i s . s e t t i n g s . b u t t o n _ c u r s o r ) ] . j o i n ( " " ) } ; S W F U p l o a d . p r o t o t y p e . g e t M o v i e E l e m e n t = f u n c t i o n ( ) { i f ( t h i s . m o v i e E l e m e n t = = u n d e f i n e d ) { t h i s . m o v i e E l e m e n t = d o c u m e n t . g e t E l e m e n t B y I d ( t h i s . m o v i e N a m e ) } i f ( t h i s . m o v i e E l e m e n t = = = n u l l ) { t h r o w " C o u l d   n o t   f i n d   F l a s h   e l e m e n t " } r e t u r n   t h i s . m o v i e E l e m e n t } ; S W F U p l o a d . p r o t o t y p e . b u i l d P a r a m S t r i n g = f u n c t i o n ( ) { v a r   C = t h i s . s e t t i n g s . p o s t _ p a r a m s ; v a r   B = [ ] ; i f ( t y p e o f   ( C ) = = = " o b j e c t " ) { f o r ( v a r   A   i n   C ) { i f ( C . h a s O w n P r o p e r t y ( A ) ) { B . p u s h ( e n c o d e U R I C o m p o n e n t ( A . t o S t r i n g ( ) ) + " = " + e n c o d e U R I C o m p o n e n t ( C [ A ] . t o S t r i n g ( ) ) ) } } } r e t u r n   B . j o i n ( " & a m p ; " ) } ; S W F U p l o a d . p r o t o t y p e . d e s t r o y = f u n c t i o n ( ) { t r y { t h i s . c a n c e l U p l o a d ( n u l l , f a l s e ) ; v a r   A = n u l l ; A = t h i s . g e t M o v i e E l e m e n t ( ) ; i f ( A & & t y p e o f   ( A . C a l l F u n c t i o n ) = = = " u n k n o w n " ) { f o r ( v a r   C   i n   A ) { t r y { i f ( t y p e o f   ( A [ C ] ) = = = " f u n c t i o n " ) { A [ C ] = n u l l } } c a t c h ( E ) { } } t r y { A . p a r e n t N o d e . r e m o v e C h i l d ( A ) } c a t c h ( B ) { } } w i n d o w [ t h i s . m o v i e N a m e ] = n u l l ; S W F U p l o a d . i n s t a n c e s [ t h i s . m o v i e N a m e ] = n u l l ; d e l e t e   S W F U p l o a d . i n s t a n c e s [ t h i s . m o v i e N a m e ] ; t h i s . m o v i e E l e m e n t = n u l l ; t h i s . s e t t i n g s = n u l l ; t h i s . c u s t o m S e t t i n g s = n u l l ; t h i s . e v e n t Q u e u e = n u l l ; t h i s . m o v i e N a m e = n u l l ; r e t u r n   t r u e } c a t c h ( D ) { r e t u r n   f a l s e } } ; S W F U p l o a d . p r o t o t y p e . d i s p l a y D e b u g I n f o = f u n c t i o n ( ) { t h i s . d e b u g ( [ " - - - S W F U p l o a d   I n s t a n c e   I n f o - - - \ n " , " V e r s i o n :   " , S W F U p l o a d . v e r s i o n , " \ n " , " M o v i e   N a m e :   " , t h i s . m o v i e N a m e , " \ n " , " S e t t i n g s : \ n " , " \ t " , " u p l o a d _ u r l :                               " , t h i s . s e t t i n g s . u p l o a d _ u r l , " \ n " , " \ t " , " f l a s h _ u r l :                                 " , t h i s . s e t t i n g s . f l a s h _ u r l , " \ n " , " \ t " , " u s e _ q u e r y _ s t r i n g :                   " , t h i s . s e t t i n g s . u s e _ q u e r y _ s t r i n g . t o S t r i n g ( ) , " \ n " , " \ t " , " r e q u e u e _ o n _ e r r o r :                   " , t h i s . s e t t i n g s . r e q u e u e _ o n _ e r r o r . t o S t r i n g ( ) , " \ n " , " \ t " , " h t t p _ s u c c e s s :                           " , t h i s . s e t t i n g s . h t t p _ s u c c e s s . j o i n ( " ,   " ) , " \ n " , " \ t " , " f i l e _ p o s t _ n a m e :                       " , t h i s . s e t t i n g s . f i l e _ p o s t _ n a m e , " \ n " , " \ t " , " p o s t _ p a r a m s :                             " , t h i s . s e t t i n g s . p o s t _ p a r a m s . t o S t r i n g ( ) , " \ n " , " \ t " , " f i l e _ t y p e s :                               " , t h i s . s e t t i n g s . f i l e _ t y p e s , " \ n " , " \ t " , " f i l e _ t y p e s _ d e s c r i p t i o n :       " , t h i s . s e t t i n g s . f i l e _ t y p e s _ d e s c r i p t i o n , " \ n " , " \ t " , " f i l e _ s i z e _ l i m i t :                     " , t h i s . s e t t i n g s . f i l e _ s i z e _ l i m i t , " \ n " , " \ t " , " f i l e _ u p l o a d _ l i m i t :                 " , t h i s . s e t t i n g s . f i l e _ u p l o a d _ l i m i t , " \ n " , " \ t " , " f i l e _ q u e u e _ l i m i t :                   " , t h i s . s e t t i n g s . f i l e _ q u e u e _ l i m i t , " \ n " , " \ t " , " d e b u g :                                         " , t h i s . s e t t i n g s . d e b u g . t o S t r i n g ( ) , " \ n " , " \ t " , " p r e v e n t _ s w f _ c a c h i n g :             " , t h i s . s e t t i n g s . p r e v e n t _ s w f _ c a c h i n g . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ p l a c e h o l d e r _ i d :         " , t h i s . s e t t i n g s . b u t t o n _ p l a c e h o l d e r _ i d . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ i m a g e _ u r l :                   " , t h i s . s e t t i n g s . b u t t o n _ i m a g e _ u r l . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ w i d t h :                           " , t h i s . s e t t i n g s . b u t t o n _ w i d t h . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ h e i g h t :                         " , t h i s . s e t t i n g s . b u t t o n _ h e i g h t . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ t e x t :                             " , t h i s . s e t t i n g s . b u t t o n _ t e x t . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ t e x t _ s t y l e :                 " , t h i s . s e t t i n g s . b u t t o n _ t e x t _ s t y l e . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ t e x t _ t o p _ p a d d i n g :     " , t h i s . s e t t i n g s . b u t t o n _ t e x t _ t o p _ p a d d i n g . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ t e x t _ l e f t _ p a d d i n g :   " , t h i s . s e t t i n g s . b u t t o n _ t e x t _ l e f t _ p a d d i n g . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ a c t i o n :                         " , t h i s . s e t t i n g s . b u t t o n _ a c t i o n . t o S t r i n g ( ) , " \ n " , " \ t " , " b u t t o n _ d i s a b l e d :                     " , t h i s . s e t t i n g s . b u t t o n _ d i s a b l e d . t o S t r i n g ( ) , " \ n " , " \ t " , " c u s t o m _ s e t t i n g s :                     " , t h i s . s e t t i n g s . c u s t o m _ s e t t i n g s . t o S t r i n g ( ) , " \ n " , " E v e n t   H a n d l e r s : \ n " , " \ t " , " s w f u p l o a d _ l o a d e d _ h a n d l e r   a s s i g n e d :     " , ( t y p e o f   t h i s . s e t t i n g s . s w f u p l o a d _ l o a d e d _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " , " \ t " , " f i l e _ d i a l o g _ s t a r t _ h a n d l e r   a s s i g n e d :   " , ( t y p e o f   t h i s . s e t t i n g s . f i l e _ d i a l o g _ s t a r t _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " , " \ t " , " f i l e _ q u e u e d _ h a n d l e r   a s s i g n e d :               " , ( t y p e o f   t h i s . s e t t i n g s . f i l e _ q u e u e d _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " , " \ t " , " f i l e _ q u e u e _ e r r o r _ h a n d l e r   a s s i g n e d :     " , ( t y p e o f   t h i s . s e t t i n g s . f i l e _ q u e u e _ e r r o r _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " , " \ t " , " u p l o a d _ s t a r t _ h a n d l e r   a s s i g n e d :             " , ( t y p e o f   t h i s . s e t t i n g s . u p l o a d _ s t a r t _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " , " \ t " , " u p l o a d _ p r o g r e s s _ h a n d l e r   a s s i g n e d :       " , ( t y p e o f   t h i s . s e t t i n g s . u p l o a d _ p r o g r e s s _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " , " \ t " , " u p l o a d _ e r r o r _ h a n d l e r   a s s i g n e d :             " , ( t y p e o f   t h i s . s e t t i n g s . u p l o a d _ e r r o r _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " , " \ t " , " u p l o a d _ s u c c e s s _ h a n d l e r   a s s i g n e d :         " , ( t y p e o f   t h i s . s e t t i n g s . u p l o a d _ s u c c e s s _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " , " \ t " , " u p l o a d _ c o m p l e t e _ h a n d l e r   a s s i g n e d :       " , ( t y p e o f   t h i s . s e t t i n g s . u p l o a d _ c o m p l e t e _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " , " \ t " , " d e b u g _ h a n d l e r   a s s i g n e d :                           " , ( t y p e o f   t h i s . s e t t i n g s . d e b u g _ h a n d l e r = = = " f u n c t i o n " ) . t o S t r i n g ( ) , " \ n " ] . j o i n ( " " ) ) } ; S W F U p l o a d . p r o t o t y p e . a d d S e t t i n g = f u n c t i o n ( B , C , A ) { i f ( C = = u n d e f i n e d ) { r e t u r n ( t h i s . s e t t i n g s [ B ] = A ) } e l s e { r e t u r n ( t h i s . s e t t i n g s [ B ] = C ) } } ; S W F U p l o a d . p r o t o t y p e . g e t S e t t i n g = f u n c t i o n ( A ) { i f ( t h i s . s e t t i n g s [ A ] ! = u n d e f i n e d ) { r e t u r n   t h i s . s e t t i n g s [ A ] } r e t u r n " " } ; S W F U p l o a d . p r o t o t y p e . c a l l F l a s h = f u n c t i o n ( f u n c t i o n N a m e , a r g u m e n t A r r a y ) { a r g u m e n t A r r a y = a r g u m e n t A r r a y | | [ ] ; v a r   m o v i e E l e m e n t = t h i s . g e t M o v i e E l e m e n t ( ) ; v a r   r e t u r n V a l u e , r e t u r n S t r i n g ; t r y { r e t u r n S t r i n g = m o v i e E l e m e n t . C a l l F u n c t i o n ( ' < i n v o k e   n a m e = " ' + f u n c t i o n N a m e + ' "   r e t u r n t y p e = " j a v a s c r i p t " > ' + _ _ f l a s h _ _ a r g u m e n t s T o X M L ( a r g u m e n t A r r a y , 0 ) + " < / i n v o k e > " ) ; r e t u r n V a l u e = e v a l ( r e t u r n S t r i n g ) } c a t c h ( e x ) { t h r o w " C a l l   t o   " + f u n c t i o n N a m e + "   f a i l e d " } i f ( r e t u r n V a l u e ! = u n d e f i n e d & & t y p e o f   r e t u r n V a l u e . p o s t = = = " o b j e c t " ) { r e t u r n V a l u e = t h i s . u n e s c a p e F i l e P o s t P a r a m s ( r e t u r n V a l u e ) } r e t u r n   r e t u r n V a l u e } ; S W F U p l o a d . p r o t o t y p e . s e l e c t F i l e = f u n c t i o n ( ) { t h i s . c a l l F l a s h ( " S e l e c t F i l e " ) } ; S W F U p l o a d . p r o t o t y p e . s e l e c t F i l e s = f u n c t i o n ( ) { t h i s . c a l l F l a s h ( " S e l e c t F i l e s " ) } ; S W F U p l o a d . p r o t o t y p e . s t a r t U p l o a d = f u n c t i o n ( A ) { t h i s . c a l l F l a s h ( " S t a r t U p l o a d " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . c a n c e l U p l o a d = f u n c t i o n ( A , B ) { i f ( B ! = = f a l s e ) { B = t r u e } t h i s . c a l l F l a s h ( " C a n c e l U p l o a d " , [ A , B ] ) } ; S W F U p l o a d . p r o t o t y p e . s t o p U p l o a d = f u n c t i o n ( ) { t h i s . c a l l F l a s h ( " S t o p U p l o a d " ) } ; S W F U p l o a d . p r o t o t y p e . g e t S t a t s = f u n c t i o n ( ) { r e t u r n   t h i s . c a l l F l a s h ( " G e t S t a t s " ) } ; S W F U p l o a d . p r o t o t y p e . s e t S t a t s = f u n c t i o n ( A ) { t h i s . c a l l F l a s h ( " S e t S t a t s " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . g e t F i l e = f u n c t i o n ( A ) { i f ( t y p e o f   ( A ) = = = " n u m b e r " ) { r e t u r n   t h i s . c a l l F l a s h ( " G e t F i l e B y I n d e x " , [ A ] ) } e l s e { r e t u r n   t h i s . c a l l F l a s h ( " G e t F i l e " , [ A ] ) } } ; S W F U p l o a d . p r o t o t y p e . a d d F i l e P a r a m = f u n c t i o n ( A , B , C ) { r e t u r n   t h i s . c a l l F l a s h ( " A d d F i l e P a r a m " , [ A , B , C ] ) } ; S W F U p l o a d . p r o t o t y p e . r e m o v e F i l e P a r a m = f u n c t i o n ( A , B ) { t h i s . c a l l F l a s h ( " R e m o v e F i l e P a r a m " , [ A , B ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t U p l o a d U R L = f u n c t i o n ( A ) { t h i s . s e t t i n g s . u p l o a d _ u r l = A . t o S t r i n g ( ) ; t h i s . c a l l F l a s h ( " S e t U p l o a d U R L " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t P o s t P a r a m s = f u n c t i o n ( A ) { t h i s . s e t t i n g s . p o s t _ p a r a m s = A ; t h i s . c a l l F l a s h ( " S e t P o s t P a r a m s " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . a d d P o s t P a r a m = f u n c t i o n ( A , B ) { t h i s . s e t t i n g s . p o s t _ p a r a m s [ A ] = B ; t h i s . c a l l F l a s h ( " S e t P o s t P a r a m s " , [ t h i s . s e t t i n g s . p o s t _ p a r a m s ] ) } ; S W F U p l o a d . p r o t o t y p e . r e m o v e P o s t P a r a m = f u n c t i o n ( A ) { d e l e t e   t h i s . s e t t i n g s . p o s t _ p a r a m s [ A ] ; t h i s . c a l l F l a s h ( " S e t P o s t P a r a m s " , [ t h i s . s e t t i n g s . p o s t _ p a r a m s ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t F i l e T y p e s = f u n c t i o n ( A , B ) { t h i s . s e t t i n g s . f i l e _ t y p e s = A ; t h i s . s e t t i n g s . f i l e _ t y p e s _ d e s c r i p t i o n = B ; t h i s . c a l l F l a s h ( " S e t F i l e T y p e s " , [ A , B ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t F i l e S i z e L i m i t = f u n c t i o n ( A ) { t h i s . s e t t i n g s . f i l e _ s i z e _ l i m i t = A ; t h i s . c a l l F l a s h ( " S e t F i l e S i z e L i m i t " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t F i l e U p l o a d L i m i t = f u n c t i o n ( A ) { t h i s . s e t t i n g s . f i l e _ u p l o a d _ l i m i t = A ; t h i s . c a l l F l a s h ( " S e t F i l e U p l o a d L i m i t " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t F i l e Q u e u e L i m i t = f u n c t i o n ( A ) { t h i s . s e t t i n g s . f i l e _ q u e u e _ l i m i t = A ; t h i s . c a l l F l a s h ( " S e t F i l e Q u e u e L i m i t " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t F i l e P o s t N a m e = f u n c t i o n ( A ) { t h i s . s e t t i n g s . f i l e _ p o s t _ n a m e = A ; t h i s . c a l l F l a s h ( " S e t F i l e P o s t N a m e " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t U s e Q u e r y S t r i n g = f u n c t i o n ( A ) { t h i s . s e t t i n g s . u s e _ q u e r y _ s t r i n g = A ; t h i s . c a l l F l a s h ( " S e t U s e Q u e r y S t r i n g " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t R e q u e u e O n E r r o r = f u n c t i o n ( A ) { t h i s . s e t t i n g s . r e q u e u e _ o n _ e r r o r = A ; t h i s . c a l l F l a s h ( " S e t R e q u e u e O n E r r o r " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t H T T P S u c c e s s = f u n c t i o n ( A ) { i f ( t y p e o f   A = = = " s t r i n g " ) { A = A . r e p l a c e ( "   " , " " ) . s p l i t ( " , " ) } t h i s . s e t t i n g s . h t t p _ s u c c e s s = A ; t h i s . c a l l F l a s h ( " S e t H T T P S u c c e s s " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t D e b u g E n a b l e d = f u n c t i o n ( A ) { t h i s . s e t t i n g s . d e b u g _ e n a b l e d = A ; t h i s . c a l l F l a s h ( " S e t D e b u g E n a b l e d " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t B u t t o n I m a g e U R L = f u n c t i o n ( A ) { i f ( A = = u n d e f i n e d ) { A = " " } t h i s . s e t t i n g s . b u t t o n _ i m a g e _ u r l = A ; t h i s . c a l l F l a s h ( " S e t B u t t o n I m a g e U R L " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t B u t t o n D i m e n s i o n s = f u n c t i o n ( C , A ) { t h i s . s e t t i n g s . b u t t o n _ w i d t h = C ; t h i s . s e t t i n g s . b u t t o n _ h e i g h t = A ; v a r   B = t h i s . g e t M o v i e E l e m e n t ( ) ; i f ( B ! = u n d e f i n e d ) { B . s t y l e . w i d t h = C + " p x " ; B . s t y l e . h e i g h t = A + " p x " } t h i s . c a l l F l a s h ( " S e t B u t t o n D i m e n s i o n s " , [ C , A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t B u t t o n T e x t = f u n c t i o n ( A ) { t h i s . s e t t i n g s . b u t t o n _ t e x t = A ; t h i s . c a l l F l a s h ( " S e t B u t t o n T e x t " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t B u t t o n T e x t P a d d i n g = f u n c t i o n ( B , A ) { t h i s . s e t t i n g s . b u t t o n _ t e x t _ t o p _ p a d d i n g = A ; t h i s . s e t t i n g s . b u t t o n _ t e x t _ l e f t _ p a d d i n g = B ; t h i s . c a l l F l a s h ( " S e t B u t t o n T e x t P a d d i n g " , [ B , A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t B u t t o n T e x t S t y l e = f u n c t i o n ( A ) { t h i s . s e t t i n g s . b u t t o n _ t e x t _ s t y l e = A ; t h i s . c a l l F l a s h ( " S e t B u t t o n T e x t S t y l e " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t B u t t o n D i s a b l e d = f u n c t i o n ( A ) { t h i s . s e t t i n g s . b u t t o n _ d i s a b l e d = A ; t h i s . c a l l F l a s h ( " S e t B u t t o n D i s a b l e d " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t B u t t o n A c t i o n = f u n c t i o n ( A ) { t h i s . s e t t i n g s . b u t t o n _ a c t i o n = A ; t h i s . c a l l F l a s h ( " S e t B u t t o n A c t i o n " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . s e t B u t t o n C u r s o r = f u n c t i o n ( A ) { t h i s . s e t t i n g s . b u t t o n _ c u r s o r = A ; t h i s . c a l l F l a s h ( " S e t B u t t o n C u r s o r " , [ A ] ) } ; S W F U p l o a d . p r o t o t y p e . q u e u e E v e n t = f u n c t i o n ( B , C ) { i f ( C = = u n d e f i n e d ) { C = [ ] } e l s e { i f ( ! ( C   i n s t a n c e o f   A r r a y ) ) { C = [ C ] } } v a r   A = t h i s ; i f ( t y p e o f   t h i s . s e t t i n g s [ B ] = = = " f u n c t i o n " ) { t h i s . e v e n t Q u e u e . p u s h ( f u n c t i o n ( ) { t h i s . s e t t i n g s [ B ] . a p p l y ( t h i s , C ) } ) ; s e t T i m e o u t ( f u n c t i o n ( ) { A . e x e c u t e N e x t E v e n t ( ) } , 0 ) } e l s e { i f ( t h i s . s e t t i n g s [ B ] ! = = n u l l ) { t h r o w " E v e n t   h a n d l e r   " + B + "   i s   u n k n o w n   o r   i s   n o t   a   f u n c t i o n " } } } ; S W F U p l o a d . p r o t o t y p e . e x e c u t e N e x t E v e n t = f u n c t i o n ( ) { v a r   A = t h i s . e v e n t Q u e u e ? t h i s . e v e n t Q u e u e . s h i f t ( ) : n u l l ; i f ( t y p e o f   ( A ) = = = " f u n c t i o n " ) { A . a p p l y ( t h i s ) } } ; S W F U p l o a d . p r o t o t y p e . u n e s c a p e F i l e P o s t P a r a m s = f u n c t i o n ( C ) { v a r   E = / [ $ ] ( [ 0 - 9 a - f ] { 4 } ) / i ; v a r   F = { } ; v a r   D ; i f ( C ! = u n d e f i n e d ) { f o r ( v a r   A   i n   C . p o s t ) { i f ( C . p o s t . h a s O w n P r o p e r t y ( A ) ) { D = A ; v a r   B ; w h i l e ( ( B = E . e x e c ( D ) ) ! = = n u l l ) { D = D . r e p l a c e ( B [ 0 ] , S t r i n g . f r o m C h a r C o d e ( p a r s e I n t ( " 0 x " + B [ 1 ] , 1 6 ) ) ) } F [ D ] = C . p o s t [ A ] } } C . p o s t = F } r e t u r n   C } ; S W F U p l o a d . p r o t o t y p e . t e s t E x t e r n a l I n t e r f a c e = f u n c t i o n ( ) { t r y { r e t u r n   t h i s . c a l l F l a s h ( " T e s t E x t e r n a l I n t e r f a c e " ) } c a t c h ( A ) { r e t u r n   f a l s e } } ; S W F U p l o a d . p r o t o t y p e . f l a s h R e a d y = f u n c t i o n ( ) { v a r   A = t h i s . g e t M o v i e E l e m e n t ( ) ; i f ( ! A ) { t h i s . d e b u g ( " F l a s h   c a l l e d   b a c k   r e a d y   b u t   t h e   f l a s h   m o v i e   c a n ' t   b e   f o u n d . " ) ; r e t u r n   } t h i s . c l e a n U p ( A ) ; t h i s . q u e u e E v e n t ( " s w f u p l o a d _ l o a d e d _ h a n d l e r " ) } ; S W F U p l o a d . p r o t o t y p e . c l e a n U p = f u n c t i o n ( A ) { t r y { i f ( t h i s . m o v i e E l e m e n t & & t y p e o f   ( A . C a l l F u n c t i o n ) = = = " u n k n o w n " ) { t h i s . d e b u g ( " R e m o v i n g   F l a s h   f u n c t i o n s   h o o k s   ( t h i s   s h o u l d   o n l y   r u n   i n   I E   a n d   s h o u l d   p r e v e n t   m e m o r y   l e a k s ) " ) ; f o r ( v a r   C   i n   A ) { t r y { i f ( t y p e o f   ( A [ C ] ) = = = " f u n c t i o n " ) { A [ C ] = n u l l } } c a t c h ( B ) { } } } } c a t c h ( D ) { } w i n d o w . _ _ f l a s h _ _ r e m o v e C a l l b a c k = f u n c t i o n ( E , F ) { t r y { i f ( E ) { E [ F ] = n u l l } } c a t c h ( G ) { } } } ; S W F U p l o a d . p r o t o t y p e . f i l e D i a l o g S t a r t = f u n c t i o n ( ) { t h i s . q u e u e E v e n t ( " f i l e _ d i a l o g _ s t a r t _ h a n d l e r " ) } ; S W F U p l o a d . p r o t o t y p e . f i l e Q u e u e d = f u n c t i o n ( A ) { A = t h i s . u n e s c a p e F i l e P o s t P a r a m s ( A ) ; t h i s . q u e u e E v e n t ( " f i l e _ q u e u e d _ h a n d l e r " , A ) } ; S W F U p l o a d . p r o t o t y p e . f i l e Q u e u e E r r o r = f u n c t i o n ( A , C , B ) { A = t h i s . u n e s c a p e F i l e P o s t P a r a m s ( A ) ; t h i s . q u e u e E v e n t ( " f i l e _ q u e u e _ e r r o r _ h a n d l e r " , [ A , C , B ] ) } ; S W F U p l o a d . p r o t o t y p e . f i l e D i a l o g C o m p l e t e = f u n c t i o n ( A , B ) { t h i s . q u e u e E v e n t ( " f i l e _ d i a l o g _ c o m p l e t e _ h a n d l e r " , [ A , B ] ) } ; S W F U p l o a d . p r o t o t y p e . u p l o a d S t a r t = f u n c t i o n ( A ) { A = t h i s . u n e s c a p e F i l e P o s t P a r a m s ( A ) ; t h i s . q u e u e E v e n t ( " r e t u r n _ u p l o a d _ s t a r t _ h a n d l e r " , A ) } ; S W F U p l o a d . p r o t o t y p e . r e t u r n U p l o a d S t a r t = f u n c t i o n ( A ) { v a r   B ; i f ( t y p e o f   t h i s . s e t t i n g s . u p l o a d _ s t a r t _ h a n d l e r = = = " f u n c t i o n " ) { A = t h i s . u n e s c a p e F i l e P o s t P a r a m s ( A ) ; B = t h i s . s e t t i n g s . u p l o a d _ s t a r t _ h a n d l e r . c a l l ( t h i s , A ) } e l s e { i f ( t h i s . s e t t i n g s . u p l o a d _ s t a r t _ h a n d l e r ! = u n d e f i n e d ) { t h r o w " u p l o a d _ s t a r t _ h a n d l e r   m u s t   b e   a   f u n c t i o n " } } i f ( B = = = u n d e f i n e d ) { B = t r u e } B = ! ! B ; t h i s . c a l l F l a s h ( " R e t u r n U p l o a d S t a r t " , [ B ] ) } ; S W F U p l o a d . p r o t o t y p e . u p l o a d P r o g r e s s = f u n c t i o n ( A , C , B ) { A = t h i s . u n e s c a p e F i l e P o s t P a r a m s ( A ) ; t h i s . q u e u e E v e n t ( " u p l o a d _ p r o g r e s s _ h a n d l e r " , [ A , C , B ] ) } ; S W F U p l o a d . p r o t o t y p e . u p l o a d E r r o r = f u n c t i o n ( A , C , B ) { A = t h i s . u n e s c a p e F i l e P o s t P a r a m s ( A ) ; t h i s . q u e u e E v e n t ( " u p l o a d _ e r r o r _ h a n d l e r " , [ A , C , B ] ) } ; S W F U p l o a d . p r o t o t y p e . u p l o a d S u c c e s s = f u n c t i o n ( B , A ) { B = t h i s . u n e s c a p e F i l e P o s t P a r a m s ( B ) ; t h i s . q u e u e E v e n t ( " u p l o a d _ s u c c e s s _ h a n d l e r " , [ B , A ] ) } ; S W F U p l o a d . p r o t o t y p e . u p l o a d C o m p l e t e = f u n c t i o n ( A ) { A = t h i s . u n e s c a p e F i l e P o s t P a r a m s ( A ) ; t h i s . q u e u e E v e n t ( " u p l o a d _ c o m p l e t e _ h a n d l e r " , A ) } ; S W F U p l o a d . p r o t o t y p e . d e b u g = f u n c t i o n ( A ) { t h i s . q u e u e E v e n t ( " d e b u g _ h a n d l e r " , A ) } ; S W F U p l o a d . p r o t o t y p e . d e b u g M e s s a g e = f u n c t i o n ( C ) { i f ( t h i s . s e t t i n g s . d e b u g ) { v a r   A , D = [ ] ; i f ( t y p e o f   C = = = " o b j e c t " & & t y p e o f   C . n a m e = = = " s t r i n g " & & t y p e o f   C . m e s s a g e = = = " s t r i n g " ) { f o r ( v a r   B   i n   C ) { i f ( C . h a s O w n P r o p e r t y ( B ) ) { D . p u s h ( B + " :   " + C [ B ] ) } } A = D . j o i n ( " \ n " ) | | " " ; D = A . s p l i t ( " \ n " ) ; A = " E X C E P T I O N :   " + D . j o i n ( " \ n E X C E P T I O N :   " ) ; S W F U p l o a d . C o n s o l e . w r i t e L i n e ( A ) } e l s e { S W F U p l o a d . C o n s o l e . w r i t e L i n e ( C ) } } } ; S W F U p l o a d . C o n s o l e = { } ; S W F U p l o a d . C o n s o l e . w r i t e L i n e = f u n c t i o n ( D ) { v a r   B , A ; t r y { B = d o c u m e n t . g e t E l e m e n t B y I d ( " S W F U p l o a d _ C o n s o l e " ) ; i f ( ! B ) { A = d o c u m e n t . c r e a t e E l e m e n t ( " f o r m " ) ; d o c u m e n t . g e t E l e m e n t s B y T a g N a m e ( " b o d y " ) [ 0 ] . a p p e n d C h i l d ( A ) ; B = d o c u m e n t . c r e a t e E l e m e n t ( " t e x t a r e a " ) ; B . i d = " S W F U p l o a d _ C o n s o l e " ; B . s t y l e . f o n t F a m i l y = " m o n o s p a c e " ; B . s e t A t t r i b u t e ( " w r a p " , " o f f " ) ; B . w r a p = " o f f " ; B . s t y l e . o v e r f l o w = " a u t o " ; B . s t y l e . w i d t h = " 7 0 0 p x " ; B . s t y l e . h e i g h t = " 3 5 0 p x " ; B . s t y l e . m a r g i n = " 5 p x " ; A . a p p e n d C h i l d ( B ) } B . v a l u e + = D + " \ n " ; B . s c r o l l T o p = B . s c r o l l H e i g h t - B . c l i e n t H e i g h t } c a t c h ( C ) { a l e r t ( " E x c e p t i o n :   " + C . n a m e + "   M e s s a g e :   " + C . m e s s a g e ) } } ; v a r   S W F U p l o a d ; i f ( t y p e o f   ( S W F U p l o a d ) = = = " f u n c t i o n " ) { S W F U p l o a d . g r a c e f u l D e g r a d a t i o n = { } ; S W F U p l o a d . p r o t o t y p e . i n i t S e t t i n g s = ( f u n c t i o n ( A ) { r e t u r n   f u n c t i o n ( ) { i f ( t y p e o f   ( A ) = = = " f u n c t i o n " ) { A . c a l l ( t h i s ) } t h i s . e n s u r e D e f a u l t = f u n c t i o n ( C , B ) { t h i s . s e t t i n g s [ C ] = ( t h i s . s e t t i n g s [ C ] = = u n d e f i n e d ) ? B : t h i s . s e t t i n g s [ C ] } ; t h i s . e n s u r e D e f a u l t ( " s w f u p l o a d _ e l e m e n t _ i d " , " s w f u p l o a d _ c o n t a i n e r " ) ; t h i s . e n s u r e D e f a u l t ( " d e g r a d e d _ e l e m e n t _ i d " , " d e g r a d e d _ c o n t a i n e r " ) ; t h i s . s e t t i n g s . u s e r _ s w f u p l o a d _ l o a d e d _ h a n d l e r = t h i s . s e t t i n g s . s w f u p l o a d _ l o a d e d _ h a n d l e r ; t h i s . s e t t i n g s . s w f u p l o a d _ l o a d e d _ h a n d l e r = S W F U p l o a d . g r a c e f u l D e g r a d a t i o n . s w f U p l o a d L o a d e d H a n d l e r ; d e l e t e   t h i s . e n s u r e D e f a u l t } } ) ( S W F U p l o a d . p r o t o t y p e . i n i t S e t t i n g s ) ; S W F U p l o a d . g r a c e f u l D e g r a d a t i o n . s w f U p l o a d L o a d e d H a n d l e r = f u n c t i o n ( ) { v a r   D , B , C , A ; D = t h i s . s e t t i n g s . s w f u p l o a d _ e l e m e n t _ i d ; C = t h i s . s e t t i n g s . d e g r a d e d _ e l e m e n t _ i d ; B = d o c u m e n t . g e t E l e m e n t B y I d ( D ) ; i f ( B ! = u n d e f i n e d ) { B . s t y l e . d i s p l a y = " b l o c k " ; A = d o c u m e n t . g e t E l e m e n t B y I d ( C ) ; i f ( A ! = u n d e f i n e d ) { A . s t y l e . d i s p l a y = " n o n e " } } i f ( t y p e o f   ( t h i s . s e t t i n g s . u s e r _ s w f u p l o a d _ l o a d e d _ h a n d l e r ) = = = " f u n c t i o n " ) { t h i s . s e t t i n g s . u s e r _ s w f u p l o a d _ l o a d e d _ h a n d l e r . a p p l y ( t h i s ) } } } f u n c t i o n   s w f U p l o a d L o a d e d ( ) { b t n S u b m i t = $ ( " i n p u t # b t n U p l o a d " ) ; b t n S u b m i t . c l i c k ( d o S u b m i t ) ; v a l i d a t e F o r m ( ) } f u n c t i o n   v a l i d a t e F o r m ( ) { b t n S u b m i t . d i s a b l e d = f a l s e } f u n c t i o n   f i l e B r o w s e ( ) { v a r   A = d o c u m e n t . g e t E l e m e n t B y I d ( " t x t F i l e N a m e " ) ; A . v a l u e = " " ; t h i s . c a n c e l U p l o a d ( ) ; t h i s . s e l e c t F i l e ( ) } f u n c t i o n   d o S u b m i t ( B ) { B = B | | w i n d o w . e v e n t ; i f ( B . s t o p P r o p a g a t i o n ) { B . s t o p P r o p a g a t i o n ( ) } B . c a n c e l B u b b l e = t r u e ; t r y { s w f u . s t a r t U p l o a d ( ) } c a t c h ( A ) { } r e t u r n   f a l s e } f u n c t i o n   u p l o a d D o n e ( ) { t r y { d o c u m e n t . f o r m s [ 0 ] . s u b m i t ( ) } c a t c h ( A ) { a l e r t ( " E r r o r   s u b m i t t i n g   f o r m " ) } } f u n c t i o n   f i l e Q u e u e E r r o r ( A , D , B ) { t r y { s w i t c h ( D ) { c a s e   S W F U p l o a d . Q U E U E _ E R R O R . Q U E U E _ L I M I T _ E X C E E D E D : a l e r t ( " Y o u   h a v e   a t t e m p t e d   t o   q u e u e   t o o   m a n y   f i l e s . \ n " + ( B = = = 0 ? " Y o u   h a v e   r e a c h e d   t h e   u p l o a d   l i m i t . " : " Y o u   m a y   s e l e c t   " + ( B > 1 ? " u p   t o   " + B + "   f i l e s . " : " o n e   f i l e . " ) ) ) ; r e t u r n   ; c a s e   S W F U p l o a d . Q U E U E _ E R R O R . F I L E _ E X C E E D S _ S I Z E _ L I M I T : a l e r t ( " T h e   f i l e   y o u   s e l e c t e d   i s   t o o   b i g . " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   F i l e   t o o   b i g ,   F i l e   n a m e :   " + A . n a m e + " ,   F i l e   s i z e :   " + A . s i z e + " ,   M e s s a g e :   " + B ) ; r e t u r n   ; c a s e   S W F U p l o a d . Q U E U E _ E R R O R . Z E R O _ B Y T E _ F I L E : a l e r t ( " T h e   f i l e   y o u   s e l e c t e d   i s   e m p t y .     P l e a s e   s e l e c t   a n o t h e r   f i l e . " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   Z e r o   b y t e   f i l e ,   F i l e   n a m e :   " + A . n a m e + " ,   F i l e   s i z e :   " + A . s i z e + " ,   M e s s a g e :   " + B ) ; r e t u r n   ; c a s e   S W F U p l o a d . Q U E U E _ E R R O R . I N V A L I D _ F I L E T Y P E : a l e r t ( " T h e   f i l e   y o u   c h o o s e   i s   n o t   a n   a l l o w e d   f i l e   t y p e . " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   I n v a l i d   F i l e   T y p e ,   F i l e   n a m e :   " + A . n a m e + " ,   F i l e   s i z e :   " + A . s i z e + " ,   M e s s a g e :   " + B ) ; r e t u r n   ; d e f a u l t : a l e r t ( " A n   e r r o r   o c c u r r e d   i n   t h e   u p l o a d .   T r y   a g a i n   l a t e r . " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   " + D + " ,   F i l e   n a m e :   " + A . n a m e + " ,   F i l e   s i z e :   " + A . s i z e + " ,   M e s s a g e :   " + B ) ; r e t u r n   } } c a t c h ( C ) { } } f u n c t i o n   f i l e Q u e u e d ( A ) { t r y { v a r   C = d o c u m e n t . g e t E l e m e n t B y I d ( " t x t F i l e N a m e " ) ; C . v a l u e = A . n a m e } c a t c h ( B ) { } } f u n c t i o n   f i l e D i a l o g C o m p l e t e ( A , B ) { v a l i d a t e F o r m ( ) } f u n c t i o n   u p l o a d P r o g r e s s ( B , E , D ) { t r y { v a r   C = M a t h . c e i l ( ( E / D ) * 1 0 0 ) ; B . i d = " s i n g l e f i l e " ; v a r   A = n e w   F i l e P r o g r e s s ( B , t h i s . c u s t o m S e t t i n g s . p r o g r e s s _ t a r g e t ) ; A . s e t P r o g r e s s ( C ) ; A . s e t S t a t u s ( " U p l o a d i n g . . . " ) } c a t c h ( F ) { } } f u n c t i o n   u p l o a d S u c c e s s ( C , B ) { t r y { C . i d = " s i n g l e f i l e " ; v a r   A = n e w   F i l e P r o g r e s s ( C , t h i s . c u s t o m S e t t i n g s . p r o g r e s s _ t a r g e t ) ; A . s e t C o m p l e t e ( ) ; A . s e t S t a t u s ( " C o m p l e t e . " ) ; A . t o g g l e C a n c e l ( f a l s e ) ; i f ( B = = = "   " ) { t h i s . c u s t o m S e t t i n g s . u p l o a d _ s u c c e s s f u l = f a l s e } e l s e { t h i s . c u s t o m S e t t i n g s . u p l o a d _ s u c c e s s f u l = t r u e ; d o c u m e n t . g e t E l e m e n t B y I d ( " h i d F i l e I D " ) . v a l u e = B } } c a t c h ( D ) { } } f u n c t i o n   u p l o a d C o m p l e t e ( B ) { t r y { i f ( t h i s . c u s t o m S e t t i n g s . u p l o a d _ s u c c e s s f u l ) { u p l o a d D o n e ( ) } e l s e { B . i d = " s i n g l e f i l e " ; v a r   A = n e w   F i l e P r o g r e s s ( B , t h i s . c u s t o m S e t t i n g s . p r o g r e s s _ t a r g e t ) ; A . s e t E r r o r ( ) ; A . s e t S t a t u s ( " F i l e   r e j e c t e d " ) ; A . t o g g l e C a n c e l ( f a l s e ) ; v a r   D = d o c u m e n t . g e t E l e m e n t B y I d ( " t x t F i l e N a m e " ) ; D . v a l u e = " " ; v a l i d a t e F o r m ( ) ; a l e r t ( " T h e r e   w a s   a   p r o b l e m   w i t h   t h e   u p l o a d . \ n T h e   s e r v e r   d i d   n o t   a c c e p t   i t . " ) } } c a t c h ( C ) { } } f u n c t i o n   u p l o a d E r r o r ( C , E , D ) { t r y { v a r   F = d o c u m e n t . g e t E l e m e n t B y I d ( " t x t F i l e N a m e " ) ; F . v a l u e = " " ; v a l i d a t e F o r m ( ) ; s w i t c h ( E ) { c a s e   S W F U p l o a d . U P L O A D _ E R R O R . M I S S I N G _ U P L O A D _ U R L : a l e r t ( " T h e r e   w a s   a   c o n f i g u r a t i o n   e r r o r .     Y o u   w i l l   n o t   b e   a b l e   t o   u p l o a d   a   r e s u m e   a t   t h i s   t i m e . " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   N o   b a c k e n d   f i l e ,   F i l e   n a m e :   " + C . n a m e + " ,   M e s s a g e :   " + D ) ; r e t u r n   ; c a s e   S W F U p l o a d . U P L O A D _ E R R O R . U P L O A D _ L I M I T _ E X C E E D E D : a l e r t ( " Y o u   m a y   o n l y   u p l o a d   1   f i l e . " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   U p l o a d   L i m i t   E x c e e d e d ,   F i l e   n a m e :   " + C . n a m e + " ,   F i l e   s i z e :   " + C . s i z e + " ,   M e s s a g e :   " + D ) ; r e t u r n   ; c a s e   S W F U p l o a d . U P L O A D _ E R R O R . F I L E _ C A N C E L L E D : c a s e   S W F U p l o a d . U P L O A D _ E R R O R . U P L O A D _ S T O P P E D : b r e a k ; d e f a u l t : a l e r t ( " A n   e r r o r   o c c u r r e d   i n   t h e   u p l o a d .   T r y   a g a i n   l a t e r . " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   " + E + " ,   F i l e   n a m e :   " + C . n a m e + " ,   F i l e   s i z e :   " + C . s i z e + " ,   M e s s a g e :   " + D ) ; r e t u r n   } C . i d = " s i n g l e f i l e " ; v a r   A = n e w   F i l e P r o g r e s s ( C , t h i s . c u s t o m S e t t i n g s . p r o g r e s s _ t a r g e t ) ; A . s e t E r r o r ( ) ; A . t o g g l e C a n c e l ( f a l s e ) ; s w i t c h ( E ) { c a s e   S W F U p l o a d . U P L O A D _ E R R O R . H T T P _ E R R O R : A . s e t S t a t u s ( " U p l o a d   E r r o r " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   H T T P   E r r o r ,   F i l e   n a m e :   " + C . n a m e + " ,   M e s s a g e :   " + D ) ; b r e a k ; c a s e   S W F U p l o a d . U P L O A D _ E R R O R . U P L O A D _ F A I L E D : A . s e t S t a t u s ( " U p l o a d   F a i l e d . " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   U p l o a d   F a i l e d ,   F i l e   n a m e :   " + C . n a m e + " ,   F i l e   s i z e :   " + C . s i z e + " ,   M e s s a g e :   " + D ) ; b r e a k ; c a s e   S W F U p l o a d . U P L O A D _ E R R O R . I O _ E R R O R : A . s e t S t a t u s ( " S e r v e r   ( I O )   E r r o r " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   I O   E r r o r ,   F i l e   n a m e :   " + C . n a m e + " ,   M e s s a g e :   " + D ) ; b r e a k ; c a s e   S W F U p l o a d . U P L O A D _ E R R O R . S E C U R I T Y _ E R R O R : A . s e t S t a t u s ( " S e c u r i t y   E r r o r " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   S e c u r i t y   E r r o r ,   F i l e   n a m e :   " + C . n a m e + " ,   M e s s a g e :   " + D ) ; b r e a k ; c a s e   S W F U p l o a d . U P L O A D _ E R R O R . F I L E _ C A N C E L L E D : A . s e t S t a t u s ( " U p l o a d   C a n c e l l e d " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   U p l o a d   C a n c e l l e d ,   F i l e   n a m e :   " + C . n a m e + " ,   M e s s a g e :   " + D ) ; b r e a k ; c a s e   S W F U p l o a d . U P L O A D _ E R R O R . U P L O A D _ S T O P P E D : A . s e t S t a t u s ( " U p l o a d   S t o p p e d " ) ; t h i s . d e b u g ( " E r r o r   C o d e :   U p l o a d   S t o p p e d ,   F i l e   n a m e :   " + C . n a m e + " ,   M e s s a g e :   " + D ) ; b r e a k } } c a t c h ( B ) { } } f u n c t i o n   F i l e P r o g r e s s ( C , A ) { t h i s . f i l e P r o g r e s s I D = C . i d ; t h i s . o p a c i t y = 1 0 0 ; t h i s . h e i g h t = 0 ; t h i s . f i l e P r o g r e s s W r a p p e r = d o c u m e n t . g e t E l e m e n t B y I d ( t h i s . f i l e P r o g r e s s I D ) ; i f ( ! t h i s . f i l e P r o g r e s s W r a p p e r ) { t h i s . f i l e P r o g r e s s W r a p p e r = d o c u m e n t . c r e a t e E l e m e n t ( " d i v " ) ; t h i s . f i l e P r o g r e s s W r a p p e r . c l a s s N a m e = " p r o g r e s s W r a p p e r " ; t h i s . f i l e P r o g r e s s W r a p p e r . i d = t h i s . f i l e P r o g r e s s I D ; t h i s . f i l e P r o g r e s s E l e m e n t = d o c u m e n t . c r e a t e E l e m e n t ( " d i v " ) ; t h i s . f i l e P r o g r e s s E l e m e n t . c l a s s N a m e = " p r o g r e s s C o n t a i n e r " ; v a r   F = d o c u m e n t . c r e a t e E l e m e n t ( " a " ) ; F . c l a s s N a m e = " p r o g r e s s C a n c e l " ; F . h r e f = " # " ; F . s t y l e . v i s i b i l i t y = " h i d d e n " ; F . a p p e n d C h i l d ( d o c u m e n t . c r e a t e T e x t N o d e ( "   " ) ) ; v a r   B = d o c u m e n t . c r e a t e E l e m e n t ( " d i v " ) ; B . c l a s s N a m e = " p r o g r e s s N a m e " ; B . a p p e n d C h i l d ( d o c u m e n t . c r e a t e T e x t N o d e ( C . n a m e ) ) ; v a r   E = d o c u m e n t . c r e a t e E l e m e n t ( " d i v " ) ; E . c l a s s N a m e = " p r o g r e s s B a r I n P r o g r e s s " ; v a r   D = d o c u m e n t . c r e a t e E l e m e n t ( " d i v " ) ; D . c l a s s N a m e = " p r o g r e s s B a r S t a t u s " ; D . i n n e r H T M L = " & n b s p ; " ; t h i s . f i l e P r o g r e s s E l e m e n t . a p p e n d C h i l d ( F ) ; t h i s . f i l e P r o g r e s s E l e m e n t . a p p e n d C h i l d ( B ) ; t h i s . f i l e P r o g r e s s E l e m e n t . a p p e n d C h i l d ( D ) ; t h i s . f i l e P r o g r e s s E l e m e n t . a p p e n d C h i l d ( E ) ; t h i s . f i l e P r o g r e s s W r a p p e r . a p p e n d C h i l d ( t h i s . f i l e P r o g r e s s E l e m e n t ) ; d o c u m e n t . g e t E l e m e n t B y I d ( A ) . a p p e n d C h i l d ( t h i s . f i l e P r o g r e s s W r a p p e r ) } e l s e { t h i s . f i l e P r o g r e s s E l e m e n t = t h i s . f i l e P r o g r e s s W r a p p e r . f i r s t C h i l d } t h i s . h e i g h t = t h i s . f i l e P r o g r e s s W r a p p e r . o f f s e t H e i g h t } F i l e P r o g r e s s . p r o t o t y p e . s e t P r o g r e s s = f u n c t i o n ( A ) { t h i s . f i l e P r o g r e s s E l e m e n t . c l a s s N a m e = " p r o g r e s s C o n t a i n e r   g r e e n " ; t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 3 ] . c l a s s N a m e = " p r o g r e s s B a r I n P r o g r e s s " ; t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 3 ] . s t y l e . w i d t h = A + " % " } ; F i l e P r o g r e s s . p r o t o t y p e . s e t C o m p l e t e = f u n c t i o n ( ) { t h i s . f i l e P r o g r e s s E l e m e n t . c l a s s N a m e = " p r o g r e s s C o n t a i n e r   b l u e " ; t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 3 ] . c l a s s N a m e = " p r o g r e s s B a r C o m p l e t e " ; t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 3 ] . s t y l e . w i d t h = " " ; v a r   A = t h i s ; s e t T i m e o u t ( f u n c t i o n ( ) { A . d i s a p p e a r ( ) } , 1 0 0 0 0 ) } ; F i l e P r o g r e s s . p r o t o t y p e . s e t E r r o r = f u n c t i o n ( ) { t h i s . f i l e P r o g r e s s E l e m e n t . c l a s s N a m e = " p r o g r e s s C o n t a i n e r   r e d " ; t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 3 ] . c l a s s N a m e = " p r o g r e s s B a r E r r o r " ; t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 3 ] . s t y l e . w i d t h = " " ; v a r   A = t h i s ; s e t T i m e o u t ( f u n c t i o n ( ) { A . d i s a p p e a r ( ) } , 5 0 0 0 ) } ; F i l e P r o g r e s s . p r o t o t y p e . s e t C a n c e l l e d = f u n c t i o n ( ) { t h i s . f i l e P r o g r e s s E l e m e n t . c l a s s N a m e = " p r o g r e s s C o n t a i n e r " ; t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 3 ] . c l a s s N a m e = " p r o g r e s s B a r E r r o r " ; t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 3 ] . s t y l e . w i d t h = " " ; v a r   A = t h i s ; s e t T i m e o u t ( f u n c t i o n ( ) { A . d i s a p p e a r ( ) } , 2 0 0 0 ) } ; F i l e P r o g r e s s . p r o t o t y p e . s e t S t a t u s = f u n c t i o n ( A ) { t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 2 ] . i n n e r H T M L = A } ; F i l e P r o g r e s s . p r o t o t y p e . t o g g l e C a n c e l = f u n c t i o n ( B , C ) { t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 0 ] . s t y l e . v i s i b i l i t y = B ? " v i s i b l e " : " h i d d e n " ; i f ( C ) { v a r   A = t h i s . f i l e P r o g r e s s I D ; t h i s . f i l e P r o g r e s s E l e m e n t . c h i l d N o d e s [ 0 ] . o n c l i c k = f u n c t i o n ( ) { C . c a n c e l U p l o a d ( A ) ; r e t u r n   f a l s e } } } ; F i l e P r o g r e s s . p r o t o t y p e . d i s a p p e a r = f u n c t i o n ( ) { v a r   E = 1 5 ; v a r   C = 4 ; v a r   B = 3 0 ; i f ( t h i s . o p a c i t y > 0 ) { t h i s . o p a c i t y - = E ; i f ( t h i s . o p a c i t y < 0 ) { t h i s . o p a c i t y = 0 } i f ( t h i s . f i l e P r o g r e s s W r a p p e r . f i l t e r s ) { t r y { t h i s . f i l e P r o g r e s s W r a p p e r . f i l t e r s . i t e m ( " D X I m a g e T r a n s f o r m . M i c r o s o f t . A l p h a " ) . o p a c i t y = t h i s . o p a c i t y } c a t c h ( D ) { t h i s . f i l e P r o g r e s s W r a p p e r . s t y l e . f i l t e r = " p r o g i d : D X I m a g e T r a n s f o r m . M i c r o s o f t . A l p h a ( o p a c i t y = " + t h i s . o p a c i t y + " ) " } } e l s e { t h i s . f i l e P r o g r e s s W r a p p e r . s t y l e . o p a c i t y = t h i s . o p a c i t y / 1 0 0 } } i f ( t h i s . h e i g h t > 0 ) { t h i s . h e i g h t - = C ; i f ( t h i s . h e i g h t < 0 ) { t h i s . h e i g h t = 0 } t h i s . f i l e P r o g r e s s W r a p p e r . s t y l e . h e i g h t = t h i s . h e i g h t + " p x " } i f ( t h i s . h e i g h t > 0 | | t h i s . o p a c i t y > 0 ) { v a r   A = t h i s ; s e t T i m e o u t ( f u n c t i o n ( ) { A . d i s a p p e a r ( ) } , B ) } e l s e { t h i s . f i l e P r o g r e s s W r a p p e r . s t y l e . d i s p l a y = " n o n e " } } ; f u n c t i o n   p a r s e U r i ( E ) { v a r   D = p a r s e U r i . o p t i o n s , A = D . p a r s e r [ D . s t r i c t M o d e ? " s t r i c t " : " l o o s e " ] . e x e c ( E ) , C = { } , B = 1 4 ; w h i l e ( B - - ) { C [ D . k e y [ B ] ] = A [ B ] | | " " } C [ D . q . n a m e ] = { } ; C [ D . k e y [ 1 2 ] ] . r e p l a c e ( D . q . p a r s e r , f u n c t i o n ( G , F , H ) { i f ( F ) { C [ D . q . n a m e ] [ F ] = H } } ) ; r e t u r n   C } p a r s e U r i . o p t i o n s = { s t r i c t M o d e : f a l s e , k e y : [ " s o u r c e " , " p r o t o c o l " , " a u t h o r i t y " , " u s e r I n f o " , " u s e r " , " p a s s w o r d " , " h o s t " , " p o r t " , " r e l a t i v e " , " p a t h " , " d i r e c t o r y " , " f i l e " , " q u e r y " , " a n c h o r " ] , q : { n a m e : " q u e r y K e y " , p a r s e r : / ( ? : ^ | & ) ( [ ^ & = ] * ) = ? ( [ ^ & ] * ) / g } , p a r s e r : { s t r i c t : / ^ ( ? : ( [ ^ : \ / ? # ] + ) : ) ? ( ? : \ / \ / ( ( ? : ( ( [ ^ : @ ] * ) : ? ( [ ^ : @ ] * ) ) ? @ ) ? ( [ ^ : \ / ? # ] * ) ( ? : : ( \ d * ) ) ? ) ) ? ( ( ( ( ? : [ ^ ? # \ / ] * \ / ) * ) ( [ ^ ? # ] * ) ) ( ? : \ ? ( [ ^ # ] * ) ) ? ( ? : # ( . * ) ) ? ) / , l o o s e : / ^ ( ? : ( ? ! [ ^ : @ ] + : [ ^ : @ \ / ] * @ ) ( [ ^ : \ / ? # . ] + ) : ) ? ( ? : \ / \ / ) ? ( ( ? : ( ( [ ^ : @ ] * ) : ? ( [ ^ : @ ] * ) ) ? @ ) ? ( [ ^ : \ / ? # ] * ) ( ? : : ( \ d * ) ) ? ) ( ( ( \ / ( ? : [ ^ ? # ] ( ? ! [ ^ ? # \ / ] * \ . [ ^ ? # \ / . ] + ( ? : [ ? # ] | $ ) ) ) * \ / ? ) ? ( [ ^ ? # \ / ] * ) ) ( ? : \ ? ( [ ^ # ] * ) ) ? ( ? : # ( . * ) ) ? ) / } } ; f u n c t i o n   c r e a t e R e q u e s t O b j e c t ( ) { t r y { x m l h t t p = w i n d o w . X M L H t t p R e q u e s t ? n e w   X M L H t t p R e q u e s t ( ) : n e w   A c t i v e X O b j e c t ( " M i c r o s o f t . X M L H T T P " ) } c a t c h ( A ) { a l e r t ( " S o r r y ,   b u t   y o u r   b r o w s e r   d o e s n ' t   s u p p o r t   X M L H t t p R e q u e s t . " ) } r e t u r n   x m l h t t p } v a r   h t t p = c r e a t e R e q u e s t O b j e c t ( ) ; v a r   s e s s = c r e a t e R e q u e s t O b j e c t ( ) ; f u n c t i o n   r e f r e s h i m g ( ) { v a r   A = " / c a p t c h a / i m a g e _ r e q . p h p " ; d o r e f r e s h ( A , d i s p l a y i m g ) } f u n c t i o n   d o r e f r e s h ( A , B ) { s e s s . o p e n ( " P O S T " , " / c a p t c h a / n e w s e s s i o n . p h p " , t r u e ) ; s e s s . s e n d ( n u l l ) ; h t t p . o p e n ( " P O S T " , A , t r u e ) ; h t t p . o n r e a d y s t a t e c h a n g e = d i s p l a y i m g ; h t t p . s e n d ( n u l l ) } f u n c t i o n   d i s p l a y i m g ( ) { i f ( h t t p . r e a d y S t a t e = = 4 ) { v a r   A = h t t p . r e s p o n s e T e x t ; $ ( " d i v . c a p t c h a i m a g e " ) . h t m l ( A ) } } f u n c t i o n   c h e c k ( ) { v a r   B = d o c u m e n t . g e t E l e m e n t B y I d ( " c a p t c h a " ) . v a l u e ; v a r   A = " p r o c e s s . p h p ? c a p t c h a = " + B ; d o c h e c k ( A , d i s p l a y c h e c k ) } f u n c t i o n   d o c h e c k ( A , B ) { h t t p . o p e n ( " G E T " , A , t r u e ) ; h t t p . o n r e a d y s t a t e c h a n g e = d i s p l a y c h e c k ; h t t p . s e n d ( n u l l ) } f u n c t i o n   d i s p l a y c h e c k ( ) { i f ( h t t p . r e a d y S t a t e = = 4 ) { v a r   A = h t t p . r e s p o n s e T e x t ; i f ( A = = " 1 " ) { d o c u m e n t . g e t E l e m e n t B y I d ( " c a p t c h a " ) . s t y l e . b o r d e r = " 1 p x   s o l i d   # 4 9 c 2 4 f " ; d o c u m e n t . g e t E l e m e n t B y I d ( " c a p t c h a " ) . s t y l e . b a c k g r o u n d = " # b c f f b f " } i f ( A = = " 0 " ) { d o c u m e n t . g e t E l e m e n t B y I d ( " c a p t c h a " ) . s t y l e . b o r d e r = " 1 p x   s o l i d   # c 2 4 9 4 9 " ; d o c u m e n t . g e t E l e m e n t B y I d ( " c a p t c h a " ) . s t y l e . b a c k g r o u n d = " # f f b c b c " } } } i f ( ! t h i s . J S O N ) { J S O N = f u n c t i o n ( ) { f u n c t i o n   f ( n ) { r e t u r n   n < 1 0 ? " 0 " + n : n } D a t e . p r o t o t y p e . t o J S O N = f u n c t i o n ( k e y ) { r e t u r n   t h i s . g e t U T C F u l l Y e a r ( ) + " - " + f ( t h i s . g e t U T C M o n t h ( ) + 1 ) + " - " + f ( t h i s . g e t U T C D a t e ( ) ) + " T " + f ( t h i s . g e t U T C H o u r s ( ) ) + " : " + f ( t h i s . g e t U T C M i n u t e s ( ) ) + " : " + f ( t h i s . g e t U T C S e c o n d s ( ) ) + " Z " } ; v a r   c x = / [ \ u 0 0 0 0 \ u 0 0 a d \ u 0 6 0 0 - \ u 0 6 0 4 \ u 0 7 0 f \ u 1 7 b 4 \ u 1 7 b 5 \ u 2 0 0 c - \ u 2 0 0 f \ u 2 0 2 8 - \ u 2 0 2 f \ u 2 0 6 0 - \ u 2 0 6 f \ u f e f f \ u f f f 0 - \ u f f f f ] / g , e s c a p e a b l e = / [ \ \ \ " \ x 0 0 - \ x 1 f \ x 7 f - \ x 9 f \ u 0 0 a d \ u 0 6 0 0 - \ u 0 6 0 4 \ u 0 7 0 f \ u 1 7 b 4 \ u 1 7 b 5 \ u 2 0 0 c - \ u 2 0 0 f \ u 2 0 2 8 - \ u 2 0 2 f \ u 2 0 6 0 - \ u 2 0 6 f \ u f e f f \ u f f f 0 - \ u f f f f ] / g , g a p , i n d e n t , m e t a = { " \ b " : " \ \ b " , " \ t " : " \ \ t " , " \ n " : " \ \ n " , " \ f " : " \ \ f " , " \ r " : " \ \ r " , ' " ' : ' \ \ " ' , " \ \ " : " \ \ \ \ " } , r e p ; f u n c t i o n   q u o t e ( s t r i n g ) { e s c a p e a b l e . l a s t I n d e x = 0 ; r e t u r n   e s c a p e a b l e . t e s t ( s t r i n g ) ? ' " ' + s t r i n g . r e p l a c e ( e s c a p e a b l e , f u n c t i o n ( a ) { v a r   c = m e t a [ a ] ; i f ( t y p e o f   c = = = " s t r i n g " ) { r e t u r n   c } r e t u r n " \ \ u " + ( " 0 0 0 0 " + ( + ( a . c h a r C o d e A t ( 0 ) ) ) . t o S t r i n g ( 1 6 ) ) . s l i c e ( - 4 ) } ) + ' " ' : ' " ' + s t r i n g + ' " ' } f u n c t i o n   s t r ( k e y , h o l d e r ) { v a r   i , k , v , l e n g t h , m i n d = g a p , p a r t i a l , v a l u e = h o l d e r [ k e y ] ; i f ( v a l u e & & t y p e o f   v a l u e = = = " o b j e c t " & & t y p e o f   v a l u e . t o J S O N = = = " f u n c t i o n " ) { v a l u e = v a l u e . t o J S O N ( k e y ) } i f ( t y p e o f   r e p = = = " f u n c t i o n " ) { v a l u e = r e p . c a l l ( h o l d e r , k e y , v a l u e ) } s w i t c h ( t y p e o f   v a l u e ) { c a s e " s t r i n g " : r e t u r n   q u o t e ( v a l u e ) ; c a s e " n u m b e r " : r e t u r n   i s F i n i t e ( v a l u e ) ? S t r i n g ( v a l u e ) : " n u l l " ; c a s e " b o o l e a n " : c a s e " n u l l " : r e t u r n   S t r i n g ( v a l u e ) ; c a s e " o b j e c t " : i f ( ! v a l u e ) { r e t u r n " n u l l " } g a p + = i n d e n t ; p a r t i a l = [ ] ; i f ( t y p e o f   v a l u e . l e n g t h = = = " n u m b e r " & & ! ( v a l u e . p r o p e r t y I s E n u m e r a b l e ( " l e n g t h " ) ) ) { l e n g t h = v a l u e . l e n g t h ; f o r ( i = 0 ; i < l e n g t h ; i + = 1 ) { p a r t i a l [ i ] = s t r ( i , v a l u e ) | | " n u l l " } v = p a r t i a l . l e n g t h = = = 0 ? " [ ] " : g a p ? " [ \ n " + g a p + p a r t i a l . j o i n ( " , \ n " + g a p ) + " \ n " + m i n d + " ] " : " [ " + p a r t i a l . j o i n ( " , " ) + " ] " ; g a p = m i n d ; r e t u r n   v } i f ( r e p & & t y p e o f   r e p = = = " o b j e c t " ) { l e n g t h = r e p . l e n g t h ; f o r ( i = 0 ; i < l e n g t h ; i + = 1 ) { k = r e p [ i ] ; i f ( t y p e o f   k = = = " s t r i n g " ) { v = s t r ( k , v a l u e , r e p ) ; i f ( v ) { p a r t i a l . p u s h ( q u o t e ( k ) + ( g a p ? " :   " : " : " ) + v ) } } } } e l s e { f o r ( k   i n   v a l u e ) { i f ( O b j e c t . h a s O w n P r o p e r t y . c a l l ( v a l u e , k ) ) { v = s t r ( k , v a l u e , r e p ) ; i f ( v ) { p a r t i a l . p u s h ( q u o t e ( k ) + ( g a p ? " :   " : " : " ) + v ) } } } } v = p a r t i a l . l e n g t h = = = 0 ? " { } " : g a p ? " { \ n " + g a p + p a r t i a l . j o i n ( " , \ n " + g a p ) + " \ n " + m i n d + " } " : " { " + p a r t i a l . j o i n ( " , " ) + " } " ; g a p = m i n d ; r e t u r n   v } } r e t u r n { s t r i n g i f y : f u n c t i o n ( v a l u e , r e p l a c e r , s p a c e ) { v a r   i ; g a p = " " ; i n d e n t = " " ; i f ( t y p e o f   s p a c e = = = " n u m b e r " ) { f o r ( i = 0 ; i < s p a c e ; i + = 1 ) { i n d e n t + = "   " } } e l s e { i f ( t y p e o f   s p a c e = = = " s t r i n g " ) { i n d e n t = s p a c e } } r e p = r e p l a c e r ; i f ( r e p l a c e r & & t y p e o f   r e p l a c e r ! = = " f u n c t i o n " & & ( t y p e o f   r e p l a c e r ! = = " o b j e c t " | | t y p e o f   r e p l a c e r . l e n g t h ! = = " n u m b e r " ) ) { t h r o w   n e w   E r r o r ( " J S O N . s t r i n g i f y " ) } r e t u r n   s t r ( " " , { " " : v a l u e } ) } , p a r s e : f u n c t i o n ( t e x t , r e v i v e r ) { v a r   j ; f u n c t i o n   w a l k ( h o l d e r , k e y ) { v a r   k , v , v a l u e = h o l d e r [ k e y ] ; i f ( v a l u e & & t y p e o f   v a l u e = = = " o b j e c t " ) { f o r ( k   i n   v a l u e ) { i f ( O b j e c t . h a s O w n P r o p e r t y . c a l l ( v a l u e , k ) ) { v = w a l k ( v a l u e , k ) ; i f ( v ! = = u n d e f i n e d ) { v a l u e [ k ] = v } e l s e { d e l e t e   v a l u e [ k ] } } } } r e t u r n   r e v i v e r . c a l l ( h o l d e r , k e y , v a l u e ) } c x . l a s t I n d e x = 0 ; i f ( c x . t e s t ( t e x t ) ) { t e x t = t e x t . r e p l a c e ( c x , f u n c t i o n ( a ) { r e t u r n " \ \ u " + ( " 0 0 0 0 " + ( + ( a . c h a r C o d e A t ( 0 ) ) ) . t o S t r i n g ( 1 6 ) ) . s l i c e ( - 4 ) } ) } i f ( / ^ [ \ ] , : { } \ s ] * $ / . t e s t ( t e x t . r e p l a c e ( / \ \ ( ? : [ " \ \ \ / b f n r t ] | u [ 0 - 9 a - f A - F ] { 4 } ) / g , " @ " ) . r e p l a c e ( / " [ ^ " \ \ \ n \ r ] * " | t r u e | f a l s e | n u l l | - ? \ d + ( ? : \ . \ d * ) ? ( ? : [ e E ] [ + \ - ] ? \ d + ) ? / g , " ] " ) . r e p l a c e ( / ( ? : ^ | : | , ) ( ? : \ s * \ [ ) + / g , " " ) ) ) { j = e v a l ( " ( " + t e x t + " ) " ) ; r e t u r n   t y p e o f   r e v i v e r = = = " f u n c t i o n " ? w a l k ( { " " : j } , " " ) : j } t h r o w   n e w   S y n t a x E r r o r ( " J S O N . p a r s e " ) } } } ( ) } w i n d o w . d h t m l H i s t o r y = { i s I E : f a l s e , i s O p e r a : f a l s e , i s S a f a r i : f a l s e , i s K o n q u e r e r : f a l s e , i s G e c k o : f a l s e , i s S u p p o r t e d : f a l s e , c r e a t e : f u n c t i o n ( I ) { v a r   C = t h i s ; w i n d o w . h i s t o r y S t o r a g e . s e t u p ( I ) ; i f ( I & & I . b a s e T i t l e ) { i f ( I . b a s e T i t l e . i n d e x O f ( " @ @ @ " ) < 0 & & h i s t o r y S t o r a g e . d e b u g M o d e ) { t h r o w   n e w   E r r o r ( " P r o g r a m m e r   e r r o r :   o p t i o n s . b a s e T i t l e   m u s t   c o n t a i n   t h e   r e p l a c e m e n t   p a r a m e t e r   ' @ @ @ '   t o   b e   u s e f u l . " ) } t h i s . b a s e T i t l e = I . b a s e T i t l e } v a r   D = n a v i g a t o r . u s e r A g e n t . t o L o w e r C a s e ( ) ; v a r   A = n a v i g a t o r . p l a t f o r m . t o L o w e r C a s e ( ) ; v a r   E = n a v i g a t o r . v e n d o r | | " " ; i f ( E = = = " K D E " ) { t h i s . i s K o n q u e r o r = t r u e ; t h i s . i s S u p p o r t e d = f a l s e } e l s e { i f ( t y p e o f   w i n d o w . o p e r a ! = = " u n d e f i n e d " ) { t h i s . i s O p e r a = t r u e ; t h i s . i s S u p p o r t e d = t r u e } e l s e { i f ( t y p e o f   d o c u m e n t . a l l ! = = " u n d e f i n e d " ) { t h i s . i s I E = t r u e ; t h i s . i s S u p p o r t e d = t r u e } e l s e { i f ( / \ ( K H T M L ,   l i k e   G e c k o \ )   S a f a r i / i . t e s t ( D ) ) { t h i s . i s S a f a r i = t r u e ; t h i s . i s S u p p o r t e d = ( A . i n d e x O f ( " m a c " ) > - 1 ) } e l s e { i f ( ( D . i n d e x O f ( " g e c k o " ) ! = - 1 ) | | ( / \ ( K H T M L ,   l i k e   G e c k o \ )   V e r s i o n \ / ( . + )   S a f a r i / i . t e s t ( D ) ) ) { t h i s . i s G e c k o = t r u e ; t h i s . i s S u p p o r t e d = t r u e } } } } } i f ( t h i s . i s S a f a r i ) { t h i s . c r e a t e S a f a r i ( ) } e l s e { i f ( t h i s . i s O p e r a ) { t h i s . c r e a t e O p e r a ( ) } } v a r   B = t h i s . g e t C u r r e n t L o c a t i o n ( ) ; t h i s . c u r r e n t L o c a t i o n = B ; i f ( t h i s . i s I E ) { i f ( I & & I . b l a n k U R L ) { v a r   F = I . b l a n k U R L ; t h i s . b l a n k U R L = ( F . i n d e x O f ( " ? " ) ! = F . l e n g t h - 1 ? F + " ? " : F ) } t h i s . c r e a t e I E ( B ) } v a r   H = f u n c t i o n ( ) { C . f i r s t L o a d = n u l l } ; t h i s . a d d E v e n t L i s t e n e r ( w i n d o w , " u n l o a d " , H ) ; i f ( t h i s . i s I E ) { t h i s . i g n o r e L o c a t i o n C h a n g e = t r u e } e l s e { i f ( ! h i s t o r y S t o r a g e . h a s K e y ( t h i s . P A G E L O A D E D S T R I N G ) ) { t h i s . i g n o r e L o c a t i o n C h a n g e = t r u e ; t h i s . f i r s t L o a d = t r u e ; h i s t o r y S t o r a g e . p u t ( t h i s . P A G E L O A D E D S T R I N G , t r u e ) } e l s e { t h i s . i g n o r e L o c a t i o n C h a n g e = f a l s e ; t h i s . f i r s t L o a d = f a l s e ; t h i s . f i r e O n N e w L i s t e n e r = t r u e } } v a r   G = f u n c t i o n ( ) { C . c h e c k L o c a t i o n ( ) } ; s e t I n t e r v a l ( G , 1 0 0 ) } , i n i t i a l i z e : f u n c t i o n ( A ) { t h i s . o r i g i n a l T i t l e = d o c u m e n t . t i t l e ; i f ( t h i s . i s I E ) { i f ( ! h i s t o r y S t o r a g e . h a s K e y ( t h i s . P A G E L O A D E D S T R I N G ) ) { t h i s . f i r e O n N e w L i s t e n e r = f a l s e ; t h i s . f i r s t L o a d = t r u e ; h i s t o r y S t o r a g e . p u t ( t h i s . P A G E L O A D E D S T R I N G , t r u e ) } e l s e { t h i s . f i r e O n N e w L i s t e n e r = t r u e ; t h i s . f i r s t L o a d = f a l s e } } i f ( A ) { t h i s . a d d L i s t e n e r ( A ) } } , a d d L i s t e n e r : f u n c t i o n ( A ) { t h i s . l i s t e n e r = A ; i f ( t h i s . f i r e O n N e w L i s t e n e r ) { t h i s . f i r e H i s t o r y E v e n t ( t h i s . c u r r e n t L o c a t i o n ) ; t h i s . f i r e O n N e w L i s t e n e r = f a l s e } } , c h a n g e T i t l e : f u n c t i o n ( D ) { v a r   B = ( D & & D . n e w T i t l e ? t h i s . b a s e T i t l e . r e p l a c e ( " @ @ @ " , D . n e w T i t l e ) : t h i s . o r i g i n a l T i t l e ) ; i f ( d o c u m e n t . t i t l e = = B ) { r e t u r n   } i f ( t h i s . i s I E ) { t h i s . i f r a m e . c o n t e n t W i n d o w . d o c u m e n t . t i t l e = B } i f ( ! t h i s . i s I E & & ! t h i s . i s O p e r a ) { v a r   C = d e c o d e U R I C o m p o n e n t ( d o c u m e n t . l o c a t i o n . h a s h ) ; i f ( C ! = " " ) { v a r   A = e n c o d e U R I C o m p o n e n t ( t h i s . r e m o v e H a s h ( C ) ) ; d o c u m e n t . l o c a t i o n . h a s h = A } e l s e { } } } , a d d : f u n c t i o n ( D , E ) { v a r   C = t h i s ; v a r   A = e n c o d e U R I C o m p o n e n t ( t h i s . r e m o v e H a s h ( D ) ) ; i f ( t h i s . i s S a f a r i ) { h i s t o r y S t o r a g e . p u t ( D , E ) ; t h i s . c u r r e n t L o c a t i o n = A ; w i n d o w . l o c a t i o n . h a s h = A ; t h i s . p u t S a f a r i S t a t e ( A ) ; t h i s . c h a n g e T i t l e ( E ) } e l s e { v a r   B = f u n c t i o n ( ) { i f ( C . c u r r e n t W a i t T i m e > 0 ) { C . c u r r e n t W a i t T i m e = C . c u r r e n t W a i t T i m e - C . w a i t T i m e } i f ( d o c u m e n t . g e t E l e m e n t B y I d ( A ) & & C . d e b u g M o d e ) { v a r   F = " E x c e p t i o n :   H i s t o r y   l o c a t i o n s   c a n   n o t   h a v e   t h e   s a m e   v a l u e   a s   _ a n y _   I D s   t h a t   m i g h t   b e   i n   t h e   d o c u m e n t ,   d u e   t o   a   b u g   i n   I E ;   p l e a s e   a s k   t h e   d e v e l o p e r   t o   c h o o s e   a   h i s t o r y   l o c a t i o n   t h a t   d o e s   n o t   m a t c h   a n y   H T M L   I D s   i n   t h i s   d o c u m e n t .   T h e   f o l l o w i n g   I D   i s   a l r e a d y   t a k e n   a n d   c a n n o t   b e   a   l o c a t i o n :   " + D ; t h r o w   n e w   E r r o r ( F ) } h i s t o r y S t o r a g e . p u t ( D , E ) ; C . i g n o r e L o c a t i o n C h a n g e = t r u e ; C . i e A t o m i c L o c a t i o n C h a n g e = t r u e ; C . c u r r e n t L o c a t i o n = A ; w i n d o w . l o c a t i o n . h a s h = A ; i f ( C . i s I E ) { C . i f r a m e . s r c = C . b l a n k U R L + A } C . i e A t o m i c L o c a t i o n C h a n g e = f a l s e ; C . c h a n g e T i t l e ( E ) } ; w i n d o w . s e t T i m e o u t ( B , t h i s . c u r r e n t W a i t T i m e ) ; t h i s . c u r r e n t W a i t T i m e = t h i s . c u r r e n t W a i t T i m e + t h i s . w a i t T i m e } } , i s F i r s t L o a d : f u n c t i o n ( ) { r e t u r n   t h i s . f i r s t L o a d } , g e t V e r s i o n : f u n c t i o n ( ) { r e t u r n   t h i s . V E R S I O N N U M B E R } , P A G E L O A D E D S T R I N G : " D h t m l H i s t o r y _ p a g e L o a d e d " , V E R S I O N N U M B E R : " 0 . 8 " , b a s e T i t l e : " @ @ @ " , o r i g i n a l T i t l e : n u l l , b l a n k U R L : " b l a n k . h t m l ? " , l i s t e n e r : n u l l , w a i t T i m e : 2 0 0 , c u r r e n t W a i t T i m e : 0 , c u r r e n t L o c a t i o n : n u l l , i f r a m e : n u l l , s a f a r i H i s t o r y S t a r t P o i n t : n u l l , s a f a r i S t a c k : n u l l , s a f a r i L e n g t h : n u l l , i g n o r e L o c a t i o n C h a n g e : n u l l , f i r e O n N e w L i s t e n e r : n u l l , f i r s t L o a d : n u l l , i e A t o m i c L o c a t i o n C h a n g e : n u l l , a d d E v e n t L i s t e n e r : f u n c t i o n ( C , B , A ) { i f ( C . a d d E v e n t L i s t e n e r ) { C . a d d E v e n t L i s t e n e r ( B , A , f a l s e ) } e l s e { i f ( C . a t t a c h E v e n t ) { C . a t t a c h E v e n t ( " o n " + B , f u n c t i o n ( ) { A ( w i n d o w . e v e n t ) } ) } } } , c r e a t e I E : f u n c t i o n ( A ) { t h i s . w a i t T i m e = 4 0 0 ; v a r   B = ( h i s t o r y S t o r a g e . d e b u g M o d e ? " w i d t h :   8 0 0 p x ; h e i g h t : 8 0 p x ; b o r d e r : 1 p x   s o l i d   b l a c k ; " : h i s t o r y S t o r a g e . h i d e S t y l e s ) ; v a r   D = " r s h H i s t o r y F r a m e " ; v a r   C = ' < i f r a m e   f r a m e b o r d e r = " 0 "   i d = " ' + D + ' "   s t y l e = " ' + B + ' "   s r c = " ' + t h i s . b l a n k U R L + A + ' " > < / i f r a m e > ' ; d o c u m e n t . w r i t e ( C ) ; t h i s . i f r a m e = d o c u m e n t . g e t E l e m e n t B y I d ( D ) } , c r e a t e O p e r a : f u n c t i o n ( ) { t h i s . w a i t T i m e = 4 0 0 ; v a r   A = ' < i m g   s r c = " j a v a s c r i p t : l o c a t i o n . h r e f = \ ' j a v a s c r i p t : d h t m l H i s t o r y . c h e c k L o c a t i o n ( ) ; \ ' ; "   s t y l e = " ' + h i s t o r y S t o r a g e . h i d e S t y l e s + ' "   / > ' ; d o c u m e n t . w r i t e ( A ) } , c r e a t e S a f a r i : f u n c t i o n ( ) { v a r   D = " r s h S a f a r i F o r m " ; v a r   C = " r s h S a f a r i S t a c k " ; v a r   B = " r s h S a f a r i L e n g t h " ; v a r   A = h i s t o r y S t o r a g e . d e b u g M o d e ? h i s t o r y S t o r a g e . s h o w S t y l e s : h i s t o r y S t o r a g e . h i d e S t y l e s ; v a r   G = ( h i s t o r y S t o r a g e . d e b u g M o d e ? " w i d t h :   8 0 0 p x ; h e i g h t : 8 0 p x ; b o r d e r : 1 p x   s o l i d   b l a c k ; " : h i s t o r y S t o r a g e . h i d e S t y l e s ) ; v a r   F = ( h i s t o r y S t o r a g e . d e b u g M o d e ? " w i d t h : 8 0 0 p x ; h e i g h t : 2 0 p x ; b o r d e r : 1 p x   s o l i d   b l a c k ; m a r g i n : 0 ; p a d d i n g : 0 ; " : h i s t o r y S t o r a g e . h i d e S t y l e s ) ; v a r   E = ' < f o r m   i d = " ' + D + ' "   s t y l e = " ' + A + ' " > < t e x t a r e a   s t y l e = " ' + G + ' "   i d = " ' + C + ' " > [ ] < / t e x t a r e a > < i n p u t   t y p e = " t e x t "   s t y l e = " ' + F + ' "   i d = " ' + B + ' "   v a l u e = " " / > < / f o r m > ' ; d o c u m e n t . w r i t e ( E ) ; t h i s . s a f a r i S t a c k = d o c u m e n t . g e t E l e m e n t B y I d ( C ) ; t h i s . s a f a r i L e n g t h = d o c u m e n t . g e t E l e m e n t B y I d ( B ) ; i f ( ! h i s t o r y S t o r a g e . h a s K e y ( t h i s . P A G E L O A D E D S T R I N G ) ) { t h i s . s a f a r i H i s t o r y S t a r t P o i n t = h i s t o r y . l e n g t h ; t h i s . s a f a r i L e n g t h . v a l u e = t h i s . s a f a r i H i s t o r y S t a r t P o i n t } e l s e { t h i s . s a f a r i H i s t o r y S t a r t P o i n t = t h i s . s a f a r i L e n g t h . v a l u e } } , g e t C u r r e n t L o c a t i o n : f u n c t i o n ( ) { v a r   A = ( t h i s . i s S a f a r i ? t h i s . g e t S a f a r i S t a t e ( ) : t h i s . g e t C u r r e n t H a s h ( ) ) ; r e t u r n   A } , g e t C u r r e n t H a s h : f u n c t i o n ( ) { v a r   B = w i n d o w . l o c a t i o n . h r e f ; v a r   A = B . i n d e x O f ( " # " ) ; r e t u r n ( A > = 0 ? B . s u b s t r ( A + 1 ) : " " ) } , g e t S a f a r i S t a c k : f u n c t i o n ( ) { v a r   A = t h i s . s a f a r i S t a c k . v a l u e ; r e t u r n   h i s t o r y S t o r a g e . f r o m J S O N ( A ) } , g e t S a f a r i S t a t e : f u n c t i o n ( ) { v a r   A = t h i s . g e t S a f a r i S t a c k ( ) ; v a r   B = A [ h i s t o r y . l e n g t h - t h i s . s a f a r i H i s t o r y S t a r t P o i n t - 1 ] ; r e t u r n   B } , p u t S a f a r i S t a t e : f u n c t i o n ( B ) { v a r   A = t h i s . g e t S a f a r i S t a c k ( ) ; A [ h i s t o r y . l e n g t h - t h i s . s a f a r i H i s t o r y S t a r t P o i n t ] = B ; t h i s . s a f a r i S t a c k . v a l u e = h i s t o r y S t o r a g e . t o J S O N ( A ) } , f i r e H i s t o r y E v e n t : f u n c t i o n ( B ) { v a r   A = d e c o d e U R I C o m p o n e n t ( B ) ; v a r   C = h i s t o r y S t o r a g e . g e t ( A ) ; t h i s . c h a n g e T i t l e ( C ) ; t h i s . l i s t e n e r . c a l l ( n u l l , A , C ) } , c h e c k L o c a t i o n : f u n c t i o n ( ) { i f ( ! t h i s . i s I E & & t h i s . i g n o r e L o c a t i o n C h a n g e ) { t h i s . i g n o r e L o c a t i o n C h a n g e = f a l s e ; r e t u r n   } i f ( ! t h i s . i s I E & & t h i s . i e A t o m i c L o c a t i o n C h a n g e ) { r e t u r n   } v a r   A = t h i s . g e t C u r r e n t L o c a t i o n ( ) ; i f ( A = = t h i s . c u r r e n t L o c a t i o n ) { r e t u r n   } t h i s . i e A t o m i c L o c a t i o n C h a n g e = t r u e ; i f ( t h i s . i s I E & & t h i s . g e t I f r a m e H a s h ( ) ! = A ) { t h i s . i f r a m e . s r c = t h i s . b l a n k U R L + A } e l s e { i f ( t h i s . i s I E ) { r e t u r n   } } t h i s . c u r r e n t L o c a t i o n = A ; t h i s . i e A t o m i c L o c a t i o n C h a n g e = f a l s e ; t h i s . f i r e H i s t o r y E v e n t ( A ) } , g e t I f r a m e H a s h : f u n c t i o n ( ) { v a r   B = t h i s . i f r a m e . c o n t e n t W i n d o w . d o c u m e n t ; v a r   A = S t r i n g ( B . l o c a t i o n . s e a r c h ) ; i f ( A . l e n g t h = = 1 & & A . c h a r A t ( 0 ) = = " ? " ) { A = " " } e l s e { i f ( A . l e n g t h > = 2 & & A . c h a r A t ( 0 ) = = " ? " ) { A = A . s u b s t r i n g ( 1 ) } } r e t u r n   A } , r e m o v e H a s h : f u n c t i o n ( B ) { v a r   A ; i f ( B = = = n u l l | | B = = = u n d e f i n e d ) { A = n u l l } e l s e { i f ( B = = = " " ) { A = " " } e l s e { i f ( B . l e n g t h = = 1 & & B . c h a r A t ( 0 ) = = " # " ) { A = " " } e l s e { i f ( B . l e n g t h > 1 & & B . c h a r A t ( 0 ) = = " # " ) { A = B . s u b s t r i n g ( 1 ) } e l s e { A = B } } } } r e t u r n   A } , i f r a m e L o a d e d : f u n c t i o n ( A ) { i f ( t h i s . i g n o r e L o c a t i o n C h a n g e ) { t h i s . i g n o r e L o c a t i o n C h a n g e = f a l s e ; r e t u r n   } v a r   B = S t r i n g ( A . s e a r c h ) ; i f ( B . l e n g t h = = 1 & & B . c h a r A t ( 0 ) = = " ? " ) { B = " " } e l s e { i f ( B . l e n g t h > = 2 & & B . c h a r A t ( 0 ) = = " ? " ) { B = B . s u b s t r i n g ( 1 ) } } w i n d o w . l o c a t i o n . h a s h = B ; t h i s . f i r e H i s t o r y E v e n t ( B ) } } ; w i n d o w . h i s t o r y S t o r a g e = { s e t u p : f u n c t i o n ( B ) { i f ( t y p e o f   B ! = = " u n d e f i n e d " ) { i f ( B . d e b u g M o d e ) { t h i s . d e b u g M o d e = B . d e b u g M o d e } i f ( B . t o J S O N ) { t h i s . t o J S O N = B . t o J S O N } i f ( B . f r o m J S O N ) { t h i s . f r o m J S O N = B . f r o m J S O N } } v a r   D = " r s h S t o r a g e F o r m " ; v a r   F = " r s h S t o r a g e F i e l d " ; v a r   A = t h i s . d e b u g M o d e ? h i s t o r y S t o r a g e . s h o w S t y l e s : h i s t o r y S t o r a g e . h i d e S t y l e s ; v a r   E = ( h i s t o r y S t o r a g e . d e b u g M o d e ? " w i d t h :   8 0 0 p x ; h e i g h t : 8 0 p x ; b o r d e r : 1 p x   s o l i d   b l a c k ; " : h i s t o r y S t o r a g e . h i d e S t y l e s ) ; v a r   C = ' < f o r m   i d = " ' + D + ' "   s t y l e = " ' + A + ' " > < t e x t a r e a   i d = " ' + F + ' "   s t y l e = " ' + E + ' " > < / t e x t a r e a > < / f o r m > ' ; d o c u m e n t . w r i t e ( C ) ; t h i s . s t o r a g e F i e l d = d o c u m e n t . g e t E l e m e n t B y I d ( F ) ; i f ( t y p e o f   w i n d o w . o p e r a ! = = " u n d e f i n e d " ) { t h i s . s t o r a g e F i e l d . f o c u s ( ) } } , p u t : f u n c t i o n ( A , C ) { v a r   B = e n c o d e U R I C o m p o n e n t ( A ) ; t h i s . a s s e r t V a l i d K e y ( B ) ; i f ( t h i s . h a s K e y ( A ) ) { t h i s . r e m o v e ( A ) } t h i s . s t o r a g e H a s h [ B ] = C ; t h i s . s a v e H a s h T a b l e ( ) } , g e t : f u n c t i o n ( A ) { v a r   C = e n c o d e U R I C o m p o n e n t ( A ) ; t h i s . a s s e r t V a l i d K e y ( C ) ; t h i s . l o a d H a s h T a b l e ( ) ; v a r   B = t h i s . s t o r a g e H a s h [ C ] ; i f ( B = = = u n d e f i n e d ) { B = n u l l } r e t u r n   B } , r e m o v e : f u n c t i o n ( A ) { v a r   B = e n c o d e U R I C o m p o n e n t ( A ) ; t h i s . a s s e r t V a l i d K e y ( B ) ; t h i s . l o a d H a s h T a b l e ( ) ; d e l e t e   t h i s . s t o r a g e H a s h [ B ] ; t h i s . s a v e H a s h T a b l e ( ) } , r e s e t : f u n c t i o n ( ) { t h i s . s t o r a g e F i e l d . v a l u e = " " ; t h i s . s t o r a g e H a s h = { } } , h a s K e y : f u n c t i o n ( A ) { v a r   B = e n c o d e U R I C o m p o n e n t ( A ) ; t h i s . a s s e r t V a l i d K e y ( B ) ; t h i s . l o a d H a s h T a b l e ( ) ; r e t u r n ( t y p e o f   t h i s . s t o r a g e H a s h [ B ] ! = = " u n d e f i n e d " ) } , i s V a l i d K e y : f u n c t i o n ( A ) { r e t u r n ( t y p e o f   A = = = " s t r i n g " ) } , s h o w S t y l e s : " b o r d e r : 0 ; m a r g i n : 0 ; p a d d i n g : 0 ; " , h i d e S t y l e s : " l e f t : - 1 0 0 0 p x ; t o p : - 1 0 0 0 p x ; w i d t h : 1 p x ; h e i g h t : 1 p x ; b o r d e r : 0 ; p o s i t i o n : a b s o l u t e ; " , d e b u g M o d e : f a l s e , s t o r a g e H a s h : { } , h a s h L o a d e d : f a l s e , s t o r a g e F i e l d : n u l l , a s s e r t V a l i d K e y : f u n c t i o n ( A ) { v a r   B = t h i s . i s V a l i d K e y ( A ) ; i f ( ! B & & t h i s . d e b u g M o d e ) { t h r o w   n e w   E r r o r ( " P l e a s e   p r o v i d e   a   v a l i d   k e y   f o r   w i n d o w . h i s t o r y S t o r a g e .   I n v a l i d   k e y   =   " + A + " . " ) } } , l o a d H a s h T a b l e : f u n c t i o n ( ) { i f ( ! t h i s . h a s h L o a d e d ) { v a r   A = t h i s . s t o r a g e F i e l d . v a l u e ; i f ( A ! = = " " & & A ! = = n u l l ) { t h i s . s t o r a g e H a s h = t h i s . f r o m J S O N ( A ) ; t h i s . h a s h L o a d e d = t r u e } } } , s a v e H a s h T a b l e : f u n c t i o n ( ) { t h i s . l o a d H a s h T a b l e ( ) ; v a r   A = t h i s . t o J S O N ( t h i s . s t o r a g e H a s h ) ; t h i s . s t o r a g e F i e l d . v a l u e = A } , t o J S O N : f u n c t i o n ( A ) { r e t u r n   A . t o J S O N S t r i n g ( ) } , f r o m J S O N : f u n c t i o n ( A ) { r e t u r n   A . p a r s e J S O N ( ) } } ; v a r   j s O p t i o n s = { j q A l e r t : { o v e r l a y : 0 , o n S h o w : f u n c t i o n ( A ) { A . w . f a d e I n ( " s l o w " ) } , o n H i d e : f u n c t i o n ( A ) { A . w . f a d e O u t ( " s l o w " ) } } } ; f u n c t i o n   v a l i d a t e F o r m ( ) { } f u n c t i o n   r e p o r t S p a m ( B , A ) { $ . p o s t ( " / a j a x _ r e p o r t _ s p a m . p h p " , " s p a m m e r = " + B + " & e m a i l _ i d = " + A , f u n c t i o n ( C ) { a l e r t ( " T h a n k s   f o r   r e p o r t i n g ! " ) } ) } f u n c t i o n   a d d H o t B l o c k ( t y p e , i d ) { $ . g e t ( " / a j a x _ h o t - b l o c k . p h p ? i d = " + i d + " & t = " + t y p e , f u n c t i o n ( d a t a ) { e v a l ( d a t a ) } ) } f u n c t i o n   r a t e P l u g i n ( f , i d ) { $ . g e t ( " / a j a x _ r a t e p l u g i n . p h p ? i d = " + i d + " & f = " + f , f u n c t i o n ( d a t a ) { e v a l ( d a t a ) } ) } f u n c t i o n   u p l o a d P i c s R u l e s ( t x t ) { $ . p o s t ( " / a j a x _ u p l o a d _ p i c s _ r u l e s . p h p " , " t x t = " + t x t , f u n c t i o n ( d a t a ) { e v a l ( d a t a ) } ) } f u n c t i o n   s h o w V i d e o P l a y e r ( A ) { $ ( d o c u m e n t . b o d y ) . a p p e n d ( ' < d i v   i d = " v i d e o _ p l a y e r "   c l a s s = " j q m W i n d o w " > < / d i v > ' ) ; $ ( " # v i d e o _ p l a y e r " ) . h t m l ( ' L o a d i n g . . .   < i m g   s r c = " / j s / b u s y . g i f " > ' ) ; $ ( " # v i d e o _ p l a y e r " ) . j q m ( { a j a x : " / a j a x _ v i d e o _ p l a y e r . p h p ? v i d = " + A , m o d a l : t r u e , o v e r l a y : 2 5 } ) . j q m S h o w ( ) } f u n c t i o n   s h o w P i c t u r e P o p u p ( A ) { $ ( d o c u m e n t . b o d y ) . a p p e n d ( ' < d i v   i d = " p i c t u r e _ p o p u p "   c l a s s = " j q m W i n d o w "   s t y l e = " w i d t h : 4 5 0 p x " > < / d i v > ' ) ; $ ( " # p i c t u r e _ p o p u p " ) . h t m l ( ' L o a d i n g . . .   < i m g   s r c = " / j s / b u s y . g i f " > ' ) ; $ ( " # p i c t u r e _ p o p u p " ) . j q m ( { a j a x : " / a j a x _ p i c t u r e _ p o p u p . p h p ? i d = " + A , m o d a l : t r u e , o v e r l a y : 2 5 } ) . j q m S h o w ( ) } f u n c t i o n   s h o w C o m p o s e P o p u p ( A ) { $ ( d o c u m e n t . b o d y ) . a p p e n d ( ' < d i v   i d = " c o m p o s e _ p o p u p "   c l a s s = " j q m W i n d o w " > < / d i v > ' ) ; $ ( " # c o m p o s e _ p o p u p " ) . h t m l ( ' L o a d i n g . . .   < i m g   s r c = " / j s / b u s y . g i f " > ' ) ; $ ( " # c o m p o s e _ p o p u p " ) . j q m ( { a j a x : " / a j a x _ m e s s a g e _ n e w . p h p ? i d = " + A , m o d a l : t r u e , o v e r l a y : 2 5 } ) . j q m S h o w ( ) } f u n c t i o n   s h o w F l i r t P o p u p ( A ) { $ ( d o c u m e n t . b o d y ) . a p p e n d ( ' < d i v   i d = " f l i r t _ p o p u p "   c l a s s = " j q m W i n d o w " > < / d i v > ' ) ; $ ( " # f l i r t _ p o p u p " ) . h t m l ( ' L o a d i n g . . .   < i m g   s r c = " / j s / b u s y . g i f " > ' ) ; $ ( " # f l i r t _ p o p u p " ) . j q m ( { a j a x : " / a j a x _ f l i r t . p h p ? i d = " + A , m o d a l : t r u e , o v e r l a y : 2 5 } ) . j q m S h o w ( ) } f u n c t i o n   c h a n g e M e s s a g e T y p e ( B ) { v a r   A = $ ( " # m e s s a g e _ a t t a c h m e n t _ " + B ) . i s ( " : v i s i b l e " ) ; s w i t c h ( A ) { c a s e   f a l s e : $ ( " # m e s s a g e _ a t t a c h m e n t _ " + B ) . h t m l ( ' < s p a n > < a   h r e f = " j a v a s c r i p t : ; "   o n c l i c k = " s h o w C o m p o s e G a l l e r y ( ' + B + ' ) " > A t t a c h   a   p r i v a t e   p i c t u r e / v i d e o   f r o m   y o u r   l i b r a r y < / a > < / s p a n > ' ) ; $ ( " # m e s s a g e _ a t t a c h m e n t _ " + B ) . s l i d e D o w n ( " f a s t " ) ; b r e a k ; d e f a u l t : d o c u m e n t . f o r m s [ " m a i l _ f o r m _ " + B ] . m e s s a g e _ t y p e . v a l u e = " S " ; $ ( " # m e s s a g e _ a t t a c h m e n t _ " + B ) . s l i d e U p ( f u n c t i o n ( ) { $ ( " # g a l l e r y _ t h u m b _ c o n t a i n e r _ " + B ) . a n i m a t e ( { w i d t h : " h i d e " } , f u n c t i o n ( ) { $ ( " # m e s s a g e _ t y p e _ l a b e l _ " + B ) . h t m l ( " S t a n d a r d   e m a i l " ) } ) } ) } } f u n c t i o n   s h o w C o m p o s e G a l l e r y ( A ) { w i n d o w . e m a i l _ i d = A ; $ ( d o c u m e n t . b o d y ) . a p p e n d ( ' < d i v   i d = " c o m p o s e _ m e s s a g e _ t y p e "   c l a s s = " j q m W i n d o w " > < / d i v > ' ) ; $ ( " # c o m p o s e _ m e s s a g e _ t y p e " ) . h t m l ( ' L o a d i n g . . .   < i m g   s r c = " / j s / b u s y . g i f " > ' ) ; $ ( " # c o m p o s e _ m e s s a g e _ t y p e " ) . j q m ( { a j a x : " / a j a x _ m a i l _ t y p e . p h p " , m o d a l : t r u e , z I n d e x : 9 9 9 9 9 9 , o v e r l a y : 2 5 } ) . j q m S h o w ( ) } f u n c t i o n   p a s s w o r d R e q u e s t ( B ) { v a r   A = " / a j a x _ g a l l e r y _ p a s s w o r d . p h p ? t = " + B ; $ . g e t ( A , f u n c t i o n ( C ) { a l e r t ( C ) } ) } f u n c t i o n   s e t I n p u t S t y l e ( ) { $ ( " i n p u t [ t y p e = s u b m i t ] " ) . a d d C l a s s ( " s u b m i t b u t t o n " ) ; $ ( " i n p u t [ t y p e = b u t t o n ] " ) . a d d C l a s s ( " s u b m i t b u t t o n " ) ; $ ( " i n p u t [ t y p e = t e x t ] " ) . a d d C l a s s ( " t e x t f i e l d " ) ; $ ( " i n p u t [ t y p e = p a s s w o r d ] " ) . a d d C l a s s ( " t e x t f i e l d " ) ; $ ( " t e x t a r e a " ) . a d d C l a s s ( " t e x t f i e l d " ) } $ ( d o c u m e n t ) . r e a d y ( f u n c t i o n ( ) { s e t I n p u t S t y l e ( ) ; $ . a j a x S e t u p ( { c a c h e : f a l s e } ) ; $ ( ) . a j a x S t o p ( s e t I n p u t S t y l e ) ; $ . m e t a d a t a . s e t T y p e ( " a t t r " , " v a l i d a t e " ) ; $ . v a l i d a t o r . m e s s a g e s . e m a i l = $ . v a l i d a t o r . m e s s a g e s . r e q u i r e d = " " } ) ;  
 
