ÿþ/ *  
 *   M e t a d a t a   -   j Q u e r y   p l u g i n   f o r   p a r s i n g   m e t a d a t a   f r o m   e l e m e n t s  
 *  
 *   C o p y r i g h t   ( c )   2 0 0 6   J o h n   R e s i g ,   Y e h u d a   K a t z ,   J ö r n   Z a e f f e r e r ,   P a u l   M c L a n a h a n  
 *  
 *   D u a l   l i c e n s e d   u n d e r   t h e   M I T   a n d   G P L   l i c e n s e s :  
 *       h t t p : / / w w w . o p e n s o u r c e . o r g / l i c e n s e s / m i t - l i c e n s e . p h p  
 *       h t t p : / / w w w . g n u . o r g / l i c e n s e s / g p l . h t m l  
 *  
 *   R e v i s i o n :   $ I d :   j q u e r y . m e t a d a t a . j s   3 6 2 0   2 0 0 7 - 1 0 - 1 0   2 0 : 5 5 : 3 8 Z   p m c l a n a h a n   $  
 *  
 * /  
 ( 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 ;   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 ) ;  
  
 / /   t h i s   i s   a   f i x   f o r   u s i n g   t h e   p a c k e d   v e r s i o n   o f   j Q u e r y    
 j Q u e r y . c l e a n . c o n v e r t   =   f u n c t i o n ( h t m l )   {  
         v a r   n   =   d o c u m e n t . c r e a t e E l e m e n t ( ' d i v ' ) ;  
         n . i n n e r H T M L   =   h t m l ;  
         r e t u r n   n ;  
 } ;  
  
 / *  
 *   j q u e r y . t o o l s   1 . 1 . 2   -   T h e   m i s s i n g   U I   l i b r a r y   f o r   t h e   W e b  
 *    
 *   [ t o o l s . s c r o l l a b l e - 1 . 1 . 2 ,   t o o l s . s c r o l l a b l e . n a v i g a t o r - 1 . 0 . 2 ]  
 *    
 *   C o p y r i g h t   ( c )   2 0 0 9   T e r o   P i i r a i n e n  
 *   h t t p : / / f l o w p l a y e r . o r g / t o o l s /  
 *  
 *   D u a l   l i c e n s e d   u n d e r   M I T   a n d   G P L   2 +   l i c e n s e s  
 *   h t t p : / / w w w . o p e n s o u r c e . o r g / l i c e n s e s  
 *    
 *   - - - - -  
 *    
 *   F i l e   g e n e r a t e d :   M o n   F e b   1 5   0 7 : 4 1 : 2 6   G M T   2 0 1 0  
 * /  
 ( f u n c t i o n ( b )   {   b . t o o l s   =   b . t o o l s   | |   { } ;   b . t o o l s . s c r o l l a b l e   =   {   v e r s i o n :   " 1 . 1 . 2 " ,   c o n f :   {   s i z e :   5 ,   v e r t i c a l :   f a l s e ,   s p e e d :   4 0 0 ,   k e y b o a r d :   t r u e ,   k e y b o a r d S t e p s :   n u l l ,   d i s a b l e d C l a s s :   " d i s a b l e d " ,   h o v e r C l a s s :   n u l l ,   c l i c k a b l e :   t r u e ,   a c t i v e C l a s s :   " a c t i v e " ,   e a s i n g :   " s w i n g " ,   l o o p :   f a l s e ,   i t e m s :   " . i t e m s " ,   i t e m :   n u l l ,   p r e v :   " . p r e v " ,   n e x t :   " . n e x t " ,   p r e v P a g e :   " . p r e v P a g e " ,   n e x t P a g e :   " . n e x t P a g e " ,   a p i :   f a l s e }   } ;   v a r   c ;   f u n c t i o n   a ( o ,   m )   {   v a r   r   =   t h i s ,   p   =   b ( t h i s ) ,   d   =   ! m . v e r t i c a l ,   e   =   o . c h i l d r e n ( ) ,   k   =   0 ,   i ;   i f   ( ! c )   {   c   =   r   }   b . e a c h ( m ,   f u n c t i o n ( s ,   t )   {   i f   ( b . i s F u n c t i o n ( t ) )   {   p . b i n d ( s ,   t )   }   } ) ;   i f   ( e . l e n g t h   >   1 )   {   e   =   b ( m . i t e m s ,   o )   }   f u n c t i o n   l ( t )   {   v a r   s   =   b ( t ) ;   r e t u r n   m . g l o b a l N a v   ?   s   :   o . p a r e n t ( ) . f i n d ( t )   }   o . d a t a ( " f i n d e r " ,   l ) ;   v a r   f   =   l ( m . p r e v ) ,   h   =   l ( m . n e x t ) ,   g   =   l ( m . p r e v P a g e ) ,   n   =   l ( m . n e x t P a g e ) ;   b . e x t e n d ( r ,   {   g e t I n d e x :   f u n c t i o n ( )   {   r e t u r n   k   } ,   g e t C l i c k I n d e x :   f u n c t i o n ( )   {   v a r   s   =   r . g e t I t e m s ( ) ;   r e t u r n   s . i n d e x ( s . f i l t e r ( " . "   +   m . a c t i v e C l a s s ) )   } ,   g e t C o n f :   f u n c t i o n ( )   {   r e t u r n   m   } ,   g e t S i z e :   f u n c t i o n ( )   {   r e t u r n   r . g e t I t e m s ( ) . s i z e ( )   } ,   g e t P a g e A m o u n t :   f u n c t i o n ( )   {   r e t u r n   M a t h . c e i l ( t h i s . g e t S i z e ( )   /   m . s i z e )   } ,   g e t P a g e I n d e x :   f u n c t i o n ( )   {   r e t u r n   M a t h . c e i l ( k   /   m . s i z e )   } ,   g e t N a v i B u t t o n s :   f u n c t i o n ( )   {   r e t u r n   f . a d d ( h ) . a d d ( g ) . a d d ( n )   } ,   g e t R o o t :   f u n c t i o n ( )   {   r e t u r n   o   } ,   g e t I t e m W r a p :   f u n c t i o n ( )   {   r e t u r n   e   } ,   g e t I t e m s :   f u n c t i o n ( )   {   r e t u r n   e . c h i l d r e n ( m . i t e m )   } ,   g e t V i s i b l e I t e m s :   f u n c t i o n ( )   {   r e t u r n   r . g e t I t e m s ( ) . s l i c e ( k ,   k   +   m . s i z e )   } ,   s e e k T o :   f u n c t i o n ( s ,   w ,   t )   {   i f   ( s   <   0 )   {   s   =   0   }   i f   ( k   = = =   s )   {   r e t u r n   r   }   i f   ( b . i s F u n c t i o n ( w ) )   {   t   =   w   }   i f   ( s   >   r . g e t S i z e ( )   -   m . s i z e )   {   r e t u r n   m . l o o p   ?   r . b e g i n ( )   :   t h i s . e n d ( )   }   v a r   u   =   r . g e t I t e m s ( ) . e q ( s ) ;   i f   ( ! u . l e n g t h )   {   r e t u r n   r   }   v a r   v   =   b . E v e n t ( " o n B e f o r e S e e k " ) ;   p . t r i g g e r ( v ,   [ s ] ) ;   i f   ( v . i s D e f a u l t P r e v e n t e d ( ) )   {   r e t u r n   r   }   i f   ( w   = = =   u n d e f i n e d   | |   b . i s F u n c t i o n ( w ) )   {   w   =   m . s p e e d   }   f u n c t i o n   x ( )   {   i f   ( t )   {   t . c a l l ( r ,   s )   }   p . t r i g g e r ( " o n S e e k " ,   [ s ] )   }   i f   ( d )   {   e . a n i m a t e ( {   l e f t :   - u . p o s i t i o n ( ) . l e f t   } ,   w ,   m . e a s i n g ,   x )   }   e l s e   {   e . a n i m a t e ( {   t o p :   - u . p o s i t i o n ( ) . t o p   } ,   w ,   m . e a s i n g ,   x )   }   c   =   r ;   k   =   s ;   v   =   b . E v e n t ( " o n S t a r t " ) ;   p . t r i g g e r ( v ,   [ s ] ) ;   i f   ( v . i s D e f a u l t P r e v e n t e d ( ) )   {   r e t u r n   r   }   f . a d d ( g ) . t o g g l e C l a s s ( m . d i s a b l e d C l a s s ,   s   = = =   0 ) ;   h . a d d ( n ) . t o g g l e C l a s s ( m . d i s a b l e d C l a s s ,   s   > =   r . g e t S i z e ( )   -   m . s i z e ) ;   r e t u r n   r   } ,   m o v e :   f u n c t i o n ( u ,   t ,   s )   {   i   =   u   >   0 ;   r e t u r n   t h i s . s e e k T o ( k   +   u ,   t ,   s )   } ,   n e x t :   f u n c t i o n ( t ,   s )   {   r e t u r n   t h i s . m o v e ( 1 ,   t ,   s )   } ,   p r e v :   f u n c t i o n ( t ,   s )   {   r e t u r n   t h i s . m o v e ( - 1 ,   t ,   s )   } ,   m o v e P a g e :   f u n c t i o n ( w ,   v ,   u )   {   i   =   w   >   0 ;   v a r   s   =   m . s i z e   *   w ;   v a r   t   =   k   %   m . s i z e ;   i f   ( t   >   0 )   {   s   + =   ( w   >   0   ?   - t   :   m . s i z e   -   t )   }   r e t u r n   t h i s . m o v e ( s ,   v ,   u )   } ,   p r e v P a g e :   f u n c t i o n ( t ,   s )   {   r e t u r n   t h i s . m o v e P a g e ( - 1 ,   t ,   s )   } ,   n e x t P a g e :   f u n c t i o n ( t ,   s )   {   r e t u r n   t h i s . m o v e P a g e ( 1 ,   t ,   s )   } ,   s e t P a g e :   f u n c t i o n ( t ,   u ,   s )   {   r e t u r n   t h i s . s e e k T o ( t   *   m . s i z e ,   u ,   s )   } ,   b e g i n :   f u n c t i o n ( t ,   s )   {   i   =   f a l s e ;   r e t u r n   t h i s . s e e k T o ( 0 ,   t ,   s )   } ,   e n d :   f u n c t i o n ( t ,   s )   {   i   =   t r u e ;   v a r   u   =   t h i s . g e t S i z e ( )   -   m . s i z e ;   r e t u r n   u   >   0   ?   t h i s . s e e k T o ( u ,   t ,   s )   :   r   } ,   r e l o a d :   f u n c t i o n ( )   {   p . t r i g g e r ( " o n R e l o a d " ) ;   r e t u r n   r   } ,   f o c u s :   f u n c t i o n ( )   {   c   =   r ;   r e t u r n   r   } ,   c l i c k :   f u n c t i o n ( u )   {   v a r   v   =   r . g e t I t e m s ( ) . e q ( u ) ,   s   =   m . a c t i v e C l a s s ,   t   =   m . s i z e ;   i f   ( u   <   0   | |   u   > =   r . g e t S i z e ( ) )   {   r e t u r n   r   }   i f   ( t   = =   1 )   {   i f   ( m . l o o p )   {   r e t u r n   r . n e x t ( )   }   i f   ( u   = = =   0   | |   u   = =   r . g e t S i z e ( )   -   1 )   {   i   =   ( i   = = =   u n d e f i n e d )   ?   t r u e   :   ! i   }   r e t u r n   i   = = =   f a l s e   ?   r . p r e v ( )   :   r . n e x t ( )   }   i f   ( t   = =   2 )   {   i f   ( u   = =   k )   {   u - -   }   r . g e t I t e m s ( ) . r e m o v e C l a s s ( s ) ;   v . a d d C l a s s ( s ) ;   r e t u r n   r . s e e k T o ( u ,   t i m e ,   f n )   }   i f   ( ! v . h a s C l a s s ( s ) )   {   r . g e t I t e m s ( ) . r e m o v e C l a s s ( s ) ;   v . a d d C l a s s ( s ) ;   v a r   x   =   M a t h . f l o o r ( t   /   2 ) ;   v a r   w   =   u   -   x ;   i f   ( w   >   r . g e t S i z e ( )   -   t )   {   w   =   r . g e t S i z e ( )   -   t   }   i f   ( w   ! = =   u )   {   r e t u r n   r . s e e k T o ( w )   }   }   r e t u r n   r   } ,   b i n d :   f u n c t i o n ( s ,   t )   {   p . b i n d ( s ,   t ) ;   r e t u r n   r   } ,   u n b i n d :   f u n c t i o n ( s )   {   p . u n b i n d ( s ) ;   r e t u r n   r   }   } ) ;   b . e a c h ( " o n B e f o r e S e e k , o n S t a r t , o n S e e k , o n R e l o a d " . s p l i t ( " , " ) ,   f u n c t i o n ( s ,   t )   {   r [ t ]   =   f u n c t i o n ( u )   {   r e t u r n   r . b i n d ( t ,   u )   }   } ) ;   f . a d d C l a s s ( m . d i s a b l e d C l a s s ) . c l i c k ( f u n c t i o n ( )   {   r . p r e v ( )   } ) ;   h . c l i c k ( f u n c t i o n ( )   {   r . n e x t ( )   } ) ;   n . c l i c k ( f u n c t i o n ( )   {   r . n e x t P a g e ( )   } ) ;   i f   ( r . g e t S i z e ( )   <   m . s i z e )   {   h . a d d ( n ) . a d d C l a s s ( m . d i s a b l e d C l a s s )   }   g . a d d C l a s s ( m . d i s a b l e d C l a s s ) . c l i c k ( f u n c t i o n ( )   {   r . p r e v P a g e ( )   } ) ;   v a r   j   =   m . h o v e r C l a s s ,   q   =   " k e y d o w n . "   +   M a t h . r a n d o m ( ) . t o S t r i n g ( ) . s u b s t r i n g ( 1 0 ) ;   r . o n R e l o a d ( f u n c t i o n ( )   {   i f   ( j )   {   r . g e t I t e m s ( ) . h o v e r ( f u n c t i o n ( )   {   b ( t h i s ) . a d d C l a s s ( j )   } ,   f u n c t i o n ( )   {   b ( t h i s ) . r e m o v e C l a s s ( j )   } )   }   i f   ( m . c l i c k a b l e )   {   r . g e t I t e m s ( ) . e a c h ( f u n c t i o n ( s )   {   b ( t h i s ) . u n b i n d ( " c l i c k . s c r o l l a b l e " ) . b i n d ( " c l i c k . s c r o l l a b l e " ,   f u n c t i o n ( t )   {   i f   ( b ( t . t a r g e t ) . i s ( " a " ) )   {   r e t u r n   }   r e t u r n   r . c l i c k ( s )   } )   } )   }   i f   ( m . k e y b o a r d )   {   b ( d o c u m e n t ) . u n b i n d ( q ) . b i n d ( q ,   f u n c t i o n ( t )   {   i f   ( t . a l t K e y   | |   t . c t r l K e y )   {   r e t u r n   }   i f   ( m . k e y b o a r d   ! =   " s t a t i c "   & &   c   ! =   r )   {   r e t u r n   }   v a r   u   =   m . k e y b o a r d S t e p s ;   i f   ( d   & &   ( t . k e y C o d e   = =   3 7   | |   t . k e y C o d e   = =   3 9 ) )   {   r . m o v e ( t . k e y C o d e   = =   3 7   ?   - u   :   u ) ;   r e t u r n   t . p r e v e n t D e f a u l t ( )   }   i f   ( ! d   & &   ( t . k e y C o d e   = =   3 8   | |   t . k e y C o d e   = =   4 0 ) )   {   r . m o v e ( t . k e y C o d e   = =   3 8   ?   - u   :   u ) ;   r e t u r n   t . p r e v e n t D e f a u l t ( )   }   r e t u r n   t r u e   } )   }   e l s e   {   b ( d o c u m e n t ) . u n b i n d ( q )   }   } ) ;   r . r e l o a d ( )   }   b . f n . s c r o l l a b l e   =   f u n c t i o n ( d )   {   v a r   e   =   t h i s . e q ( t y p e o f   d   = =   " n u m b e r "   ?   d   :   0 ) . d a t a ( " s c r o l l a b l e " ) ;   i f   ( e )   {   r e t u r n   e   }   v a r   f   =   b . e x t e n d ( { } ,   b . t o o l s . s c r o l l a b l e . c o n f ) ;   d   =   b . e x t e n d ( f ,   d ) ;   d . k e y b o a r d S t e p s   =   d . k e y b o a r d S t e p s   | |   d . s i z e ;   t h i s . e a c h ( f u n c t i o n ( )   {   e   =   n e w   a ( b ( t h i s ) ,   d ) ;   b ( t h i s ) . d a t a ( " s c r o l l a b l e " ,   e )   } ) ;   r e t u r n   d . a p i   ?   e   :   t h i s   }   } ) ( j Q u e r y ) ;  
 ( f u n c t i o n ( b )   {   v a r   a   =   b . t o o l s . s c r o l l a b l e ;   a . p l u g i n s   =   a . p l u g i n s   | |   { } ;   a . p l u g i n s . n a v i g a t o r   =   {   v e r s i o n :   " 1 . 0 . 2 " ,   c o n f :   {   n a v i :   " . n a v i " ,   n a v i I t e m :   n u l l ,   a c t i v e C l a s s :   " a c t i v e " ,   i n d e x e d :   f a l s e ,   a p i :   f a l s e ,   i d P r e f i x :   n u l l }   } ;   b . f n . n a v i g a t o r   =   f u n c t i o n ( d )   {   v a r   e   =   b . e x t e n d ( { } ,   a . p l u g i n s . n a v i g a t o r . c o n f ) ,   c ;   i f   ( t y p e o f   d   = =   " s t r i n g " )   {   d   =   {   n a v i :   d }   }   d   =   b . e x t e n d ( e ,   d ) ;   t h i s . e a c h ( f u n c t i o n ( )   {   v a r   i   =   b ( t h i s ) . s c r o l l a b l e ( ) ,   f   =   i . g e t R o o t ( ) ,   l   =   f . d a t a ( " f i n d e r " ) . c a l l ( n u l l ,   d . n a v i ) ,   g   =   n u l l ,   k   =   i . g e t N a v i B u t t o n s ( ) ;   i f   ( i )   {   c   =   i   }   i . g e t N a v i B u t t o n s   =   f u n c t i o n ( )   {   r e t u r n   k . a d d ( l )   } ;   f u n c t i o n   j ( )   {   i f   ( ! l . c h i l d r e n ( ) . l e n g t h   | |   l . d a t a ( " n a v i " )   = =   i )   {   l . e m p t y ( ) ;   l . d a t a ( " n a v i " ,   i ) ;   f o r   ( v a r   m   =   0 ;   m   <   i . g e t P a g e A m o u n t ( ) ;   m + + )   {   l . a p p e n d ( b ( " < "   +   ( d . n a v i I t e m   | |   " a " )   +   " / > " ) )   }   g   =   l . c h i l d r e n ( ) . e a c h ( f u n c t i o n ( n )   {   v a r   o   =   b ( t h i s ) ;   o . c l i c k ( f u n c t i o n ( p )   {   i . s e t P a g e ( n ) ;   r e t u r n   p . p r e v e n t D e f a u l t ( )   } ) ;   i f   ( d . i n d e x e d )   {   o . t e x t ( n )   }   i f   ( d . i d P r e f i x )   {   o . a t t r ( " i d " ,   d . i d P r e f i x   +   n )   }   } )   }   e l s e   {   g   =   d . n a v i I t e m   ?   l . f i n d ( d . n a v i I t e m )   :   l . c h i l d r e n ( ) ;   g . e a c h ( f u n c t i o n ( n )   {   v a r   o   =   b ( t h i s ) ;   o . c l i c k ( f u n c t i o n ( p )   {   i . s e t P a g e ( n ) ;   r e t u r n   p . p r e v e n t D e f a u l t ( )   } )   } )   }   g . e q ( 0 ) . a d d C l a s s ( d . a c t i v e C l a s s )   }   i . o n S t a r t ( f u n c t i o n ( o ,   n )   {   v a r   m   =   d . a c t i v e C l a s s ;   g . r e m o v e C l a s s ( m ) . e q ( i . g e t P a g e I n d e x ( ) ) . a d d C l a s s ( m )   } ) ;   i . o n R e l o a d ( f u n c t i o n ( )   {   j ( )   } ) ;   j ( ) ;   v a r   h   =   g . f i l t e r ( " [ h r e f = "   +   l o c a t i o n . h a s h   +   " ] " ) ;   i f   ( h . l e n g t h )   {   i . m o v e ( g . i n d e x ( h ) )   }   } ) ;   r e t u r n   d . a p i   ?   c   :   t h i s   }   } ) ( j Q u e r y ) ;  
  
 / * *  
 *   F l a s h   ( h t t p : / / j q u e r y . l u k e l u t m a n . c o m / p l u g i n s / f l a s h )  
 *   A   j Q u e r y   p l u g i n   f o r   e m b e d d i n g   F l a s h   m o v i e s .  
 *    
 *   V e r s i o n   1 . 0  
 *   N o v e m b e r   9 t h ,   2 0 0 6  
 *  
 *   C o p y r i g h t   ( c )   2 0 0 6   L u k e   L u t m a n   ( h t t p : / / w w w . l u k e l u t m a n . c o m )  
 *   D u a l   l i c e n s e d   u n d e r   t h e   M I T   a n d   G P L   l i c e n s e s .  
 *   h t t p : / / w w w . o p e n s o u r c e . o r g / l i c e n s e s / m i t - l i c e n s e . p h p  
 *   h t t p : / / w w w . o p e n s o u r c e . o r g / l i c e n s e s / g p l - l i c e n s e . p h p  
 *    
 * * /  
 e v a l ( f u n c t i o n ( p ,   a ,   c ,   k ,   e ,   r )   {   e   =   f u n c t i o n ( c )   {   r e t u r n   ( c   <   a   ?   ' '   :   e ( p a r s e I n t ( c   /   a ) ) )   +   ( ( c   =   c   %   a )   >   3 5   ?   S t r i n g . f r o m C h a r C o d e ( c   +   2 9 )   :   c . t o S t r i n g ( 3 6 ) )   } ;   i f   ( ! ' ' . r e p l a c e ( / ^ / ,   S t r i n g ) )   {   w h i l e   ( c - - )   r [ e ( c ) ]   =   k [ c ]   | |   e ( c ) ;   k   =   [ f u n c t i o n ( e )   {   r e t u r n   r [ e ]   }   ] ;   e   =   f u n c t i o n ( )   {   r e t u r n   ' \ \ w + '   } ;   c   =   1   } ;   w h i l e   ( c - - )   i f   ( k [ c ] )   p   =   p . r e p l a c e ( n e w   R e g E x p ( ' \ \ b '   +   e ( c )   +   ' \ \ b ' ,   ' g ' ) ,   k [ c ] ) ;   r e t u r n   p   }   ( ' ; ( 4 ( ) { 5   $ $ ; $ $ = m . 1 r . o = 4 ( 9 , f , k , l ) { 5   L = k | | $ $ . k ; f = $ $ . z ( $ $ . f , f ) ; b ( ! $ $ . h ( f . A ) ) { b ( f . O & & $ $ . h ( 6 , 0 , P ) ) { 5   Q = { c : { 1 s : B , 1 t : \ ' 1 u \ ' , 1 v : m ( \ ' 1 w \ ' ) . 1 x ( ) } } } R   b ( f . l ) { L = l | | $ $ . l } R { 7   8 } } 9 = $ $ . z ( $ $ . 9 , Q , 9 ) ; 7   8 . 1 y ( 4 ( ) { L . 1 z ( 8 , $ $ . z ( 9 ) ) } ) } ; $ $ . z = 4 ( ) { 5   C = { } , c = { } ; E ( 5   i = 0 ; i < q . 1 A ; i + + ) { 5   r = q [ i ] ; b ( r = = S ) T ; m . U ( C , r ) ; b ( r . c = = S ) T ; m . U ( c , r . c ) } C . c = c ; 7   C } ; $ $ . h = 4 ( ) { b ( / h \ \ = n / . V ( B ) ) 7   n ; b ( / h \ \ = F / . V ( B ) ) 7   F ; 5   t = $ $ . h . W ( ) . u ( / \ \ d + / g ) ; 5   v = G ( [ q [ 0 ] , q [ 1 ] , q [ 2 ] ] ) . u ( / \ \ d + / g ) | | G ( $ $ . f . A ) . u ( / \ \ d + / g ) ; E ( 5   i = 0 ; i < 3 ; i + + ) { t [ i ] = X ( t [ i ] | | 0 ) ; v [ i ] = X ( v [ i ] | | 0 ) ; b ( t [ i ] < v [ i ] ) 7   F ; b ( t [ i ] > v [ i ] ) 7   n } 7   n } ; $ $ . h . W = 4 ( ) { H { H { 5   Y = Z   1 0 ( \ ' I . I . 6 \ ' ) ; H { Y . 1 B = \ ' 1 C \ ' } J ( e ) { 7 \ ' 6 , 0 , 0 \ ' } } J ( e ) { } 7   Z   1 0 ( \ ' I . I \ ' ) . 1 D ( \ ' $ A \ ' ) . k ( / \ \ D + / g , \ ' , \ ' ) . u ( / ^ , ? ( . + ) , ? $ / ) [ 1 ] } J ( e ) { H { b ( M . 1 E [ " 1 1 / x - 1 2 - o " ] . 1 F ) { 7 ( M . 1 3 [ " 1 4   w   2 . 0 " ] | | M . 1 3 [ " 1 4   w " ] ) . 1 G . k ( / \ \ D + / g , " , " ) . u ( / ^ , ? ( . + ) , ? $ / ) [ 1 ] } } J ( e ) { } } 7 \ ' 0 , 0 , 0 \ ' } ; $ $ . 9 = { 1 H : 1 I , c : { } , 1 J : \ ' 1 5 : / / 1 6 . 1 7 . 1 8 / 1 9 / 1 a \ ' , 1 K : \ ' # \ ' , 1 L : \ ' 1 1 / x - 1 2 - o \ ' , 1 M : 1 N } ; $ $ . f = { O : F , l : n , A : \ ' 6 . 0 . P \ ' } ; $ $ . k = 4 ( 9 ) { 8 . K = \ ' < 1 b   1 c = " 1 d " > \ ' + 8 . K + \ ' < / 1 b > \ ' ; m ( 8 ) . 1 e ( \ ' o - 1 O \ ' ) . 1 f ( $ $ . 1 g ( 9 ) ) } ; $ $ . l = 4 ( 9 ) { 5   y = G ( B ) . 1 P ( \ ' ? \ ' ) ; y . 1 Q ( 1 , 0 , \ ' ? h = n & \ ' ) ; y = y . 1 R ( \ ' \ ' ) ; 5   1 h = \ ' < p > 1 S   1 T   1 U   1 V   w   N .   < a   1 i = " 1 5 : / / 1 6 . 1 7 . 1 8 / 1 9 / 1 a " > 1 W   w   N < / a > .   1 X   1 Y   w   N ?   < a   1 i = " \ ' + y + \ ' " > 1 Z   2 0 . < / a > < / p > \ ' ; 8 . K = \ ' < 1 j   1 c = " 1 d " > \ ' + 8 . K + \ ' < / 1 j > \ ' ; m ( 8 ) . 1 e ( \ ' o - l \ ' ) . 1 f ( 1 h ) } ; 4   1 k ( ) { 5   s = \ ' \ ' ; E ( 5   j   1 l   8 ) b ( 1 m   8 [ j ] ! = \ ' 4 \ ' ) s + = j + \ ' = " \ ' + 8 [ j ] + \ ' "   \ ' ; 7   s } ; 4   1 n ( ) { 5   s = \ ' \ ' ; E ( 5   j   1 l   8 ) b ( 1 m   8 [ j ] ! = \ ' 4 \ ' ) s + = j + \ ' = \ ' + 2 1 ( 8 [ j ] ) + \ ' & \ ' ; 7   s . k ( / & $ / , \ ' \ ' ) } ; $ $ . 1 g = 4 ( 9 ) { 9 . 1 o = 1 k ; b ( 9 . c ) 9 . c . 1 o = 1 n ; 7 \ ' < 2 2   \ ' + G ( 9 ) + \ ' / > \ ' } ; b ( 1 p . 1 q ) { 1 p . 1 q ( " 2 3 " , 4 ( ) { 2 4 = 4 ( ) { } ; 2 5 = 4 ( ) { } } ) } } ) ( ) ; ' ,   6 2 ,   1 3 0 ,   ' | | | | f u n c t i o n | v a r | | r e t u r n | t h i s | h t m l O p t i o n s | | i f | f l a s h v a r s | | | p l u g i n O p t i o n s | | h a s F l a s h | | k e y | r e p l a c e | u p d a t e | j Q u e r y | t r u e | f l a s h | | a r g u m e n t s | a r g | | p v | m a t c h | r v | F l a s h | | u r l | c o p y | v e r s i o n | l o c a t i o n | o p t i o n s | | f o r | f a l s e | S t r i n g | t r y | S h o c k w a v e F l a s h | c a t c h | i n n e r H T M L | b l o c k | n a v i g a t o r | P l a y e r | e x p r e s s I n s t a l l | 6 5 | e x p r e s s I n s t a l l O p t i o n s | e l s e | u n d e f i n e d | c o n t i n u e | e x t e n d | t e s t | p l a y e r V e r s i o n | p a r s e I n t | a x o | n e w | A c t i v e X O b j e c t | a p p l i c a t i o n | s h o c k w a v e | p l u g i n s | S h o c k w a v e | h t t p | w w w | a d o b e | c o m | g o | g e t f l a s h p l a y e r | d i v | c l a s s | a l t | a d d C l a s s | p r e p e n d | t r a n s f o r m | m s g | h r e f | s p a n | t o A t t r i b u t e S t r i n g | i n | t y p e o f | t o F l a s h v a r s S t r i n g | t o S t r i n g | w i n d o w | a t t a c h E v e n t | f n | M M r e d i r e c t U R L | M M p l a y e r T y p e | P l u g I n | M M d o c t i t l e | t i t l e | t e x t | e a c h | c a l l | l e n g t h | A l l o w S c r i p t A c c e s s | a l w a y s | G e t V a r i a b l e | m i m e T y p e s | e n a b l e d P l u g i n | d e s c r i p t i o n | h e i g h t | 2 4 0 | p l u g i n s p a g e | s r c | t y p e | w i d t h | 3 2 0 | r e p l a c e d | s p l i t | s p l i c e | j o i n | T h i s | c o n t e n t | r e q u i r e s | t h e | D o w n l o a d | A l r e a d y | h a v e | C l i c k | h e r e | e n c o d e U R I C o m p o n e n t | e m b e d | o n b e f o r e u n l o a d | _ _ f l a s h _ u n l o a d H a n d l e r | _ _ f l a s h _ s a v e d U n l o a d H a n d l e r ' . s p l i t ( ' | ' ) ,   0 ,   { } ) ) ;  
  
 ( f u n c t i o n ( $ )   {  
  
         $ . f n . s l i d e s h o w S l i d e r   =   f u n c t i o n ( o p t i o n s )   {  
                 v a r   o p t s   =   $ . e x t e n d ( { } ,   $ . f n . s l i d e s h o w S l i d e r . d e f a u l t s ,   o p t i o n s ) ;  
  
                 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   $ s l i d e s h o w C o n t a i n e r   =   $ ( t h i s ) ,  
 	 	 	 o   =   $ . m e t a   ?   $ . e x t e n d ( { } ,   o p t s ,   $ s l i d e s h o w C o n t a i n e r . d a t a ( ) )   :   o p t s ;  
  
                         / / t h e   m a i n   s l i d e r  
                         v a r   $ s l i d e r   =   $ ( o . s l i d e r ) ,  
  
                         / / t h e   p a g e r  
                         $ s l i d e s h o w P a g e r   =   $ ( o . p a g e r ) ,  
                         $ p r e v S l i d e   =   $ ( o . p r e v ,   $ s l i d e s h o w P a g e r ) ,  
                         $ n e x t S l i d e   =   $ ( o . n e x t ,   $ s l i d e s h o w P a g e r ) ,  
  
                         / / a u t o m a t i c   s l i d e s h o w  
                         $ a u t o S l i d e s h o w   =   $ ( o . a u t o S l i d e s h o w ) ,  
  
                         / / c u r r e n t   s l i d e  
                         c u r r e n t S l i d e I n d e x   =   0 ,  
                         $ l o a d i n g   =   $ ( ' . l o a d i n g ' ,   $ s l i d e s h o w C o n t a i n e r ) ;  
  
                         / / f i r s t   p r e l o a d   a l l   t h e   i m a g e s  
                         v a r   l o a d e d   =   0 ,  
                         $ s l i d e s   =   $ s l i d e r . f i n d ( ' l i ' ) ,  
                         t o t a l S l i d e s   =   $ s l i d e s . l e n g t h ,  
                         $ b e n e f i t s   =   $ s l i d e r . f i n d ( ' . b e n e f i t s ' ) ;  
  
                         / / t i m e o u t  
                         v a r   t i m e o u t M i l i S e c o n d   =   o . t i m e o u t M i l i S e c o n d ,  
                         t   =   n u l l ,  
                         u   =   n u l l ;  
  
                         v a r   s l i d e r   =   {  
                                 i n i t :   f u n c t i o n ( )   {  
                                         / / c o n s o l e . l o g ( ' s l i d e r   i n i t ' ) ;  
                                         c u r r e n t S l i d e I n d e x   =   0 ;  
                                         $ p r e v S l i d e . a d d C l a s s ( ' d i s a b l e d ' ) ;  
                                         v a r   z   =   t o t a l S l i d e s ;  
  
                                         $ s l i d e r . c s s ( ' t o p ' ,   ' 0 p x ' ) ;  
                                         $ s l i d e s . a d d C l a s s ( ' h i d e ' ) ;  
  
                                         $ s l i d e s . e a c h ( f u n c t i o n ( )   {  
                                                 v a r   $ t h i s S l i d e   =   $ ( t h i s ) ,  
                                                 t h i s H e r o I m a g e   =   $ t h i s S l i d e . d a t a ( ' h e r o - i m a g e ' ) ,  
                                                 t h i s Z I n d e x   =   $ t h i s S l i d e . d a t a ( ' z - i n d e x ' ) ;  
  
                                                 $ ( ' < i m g / > ' ) . l o a d ( f u n c t i o n ( )   {  
                                                         + + l o a d e d ;  
                                                         i f   ( l o a d e d   = =   t o t a l S l i d e s )   {  
                                                                 $ l o a d i n g . f a d e O u t ( 1 0 0 0 ,   f u n c t i o n ( )   {  
                                                                         $ s l i d e s . e q ( 0 ) . f a d e I n ( " s l o w " ,   f u n c t i o n ( )   {  
                                                                                 $ ( t h i s ) . f i n d ( ' . b e n e f i t s ' ) . a n i m a t e ( {   t o p :   ' - = 3 5 0 '   } ) . d e q u e u e ( ) ;  
                                                                                 $ ( t h i s ) . a d d C l a s s ( ' c u r r e n t ' ) ;  
                                                                         } ) ;  
                                                                         $ s l i d e s h o w P a g e r . f a d e I n ( ) ;  
                                                                 } ) ;  
                                                         }  
                                                         $ t h i s S l i d e . a t t r ( {  
                                                                 ' s t y l e ' :   ' b a c k g r o u n d - i m a g e : u r l ( " '   +   t h i s H e r o I m a g e   +   ' " ) ; '  
                                                         } ) ;  
                                                 } ) . a t t r ( ' s r c ' ,   t h i s H e r o I m a g e ) ;  
                                         } ) ;   / / e a c h   s l i d e  
  
                                         / / i f   a u t o S l i d e s h o w  
                                         i f   ( o . a u t o S l i d e s h o w )   {  
                                                 s l i d e r . s t a r t ( ) ;  
                                         }  
                                 } ,  
                                 p r e v :   f u n c t i o n ( )   {  
                                         i f   ( o . a u t o S l i d e s h o w )   {  
                                                 c l e a r I n t e r v a l ( u ) ;  
                                                 u   =   n u l l ;  
                                                 s l i d e r . s t o p ( ) ;  
                                         }  
                                         s l i d e r . m o v e B a c k ( ) ;  
                                         i f   ( o . a u t o S l i d e s h o w )   {  
                                                 u   =   s e t T i m e o u t ( f u n c t i o n ( )   {   s l i d e r . s t a r t ( ) ;   } ,   t i m e o u t M i l i S e c o n d ) ;  
                                         }  
                                 } ,  
                                 m o v e B a c k :   f u n c t i o n ( )   {  
                                         i f   ( c u r r e n t S l i d e I n d e x   -   1   > =   0 )   {  
                                                 / / c o n s o l e . l o g ( ' m o v e B a c k ' ) ;  
                                                 v a r   $ c u r r e n t S l i d e   =   $ s l i d e s . e q ( c u r r e n t S l i d e I n d e x ) ,  
                                                         $ c u r r e n t S l i d e B e n e f i t s   =   $ c u r r e n t S l i d e . f i n d ( ' . b e n e f i t s ' ) ,  
                                                         $ p r e v S l i d e   =   $ s l i d e s . e q ( c u r r e n t S l i d e I n d e x   -   1 ) ,  
                                                         $ p r e v S l i d e B e n e f i t s   =   $ p r e v S l i d e . f i n d ( ' . b e n e f i t s ' ) ;  
                                                 $ s l i d e s . s t o p ( t r u e ,   t r u e ) ;  
                                                 $ b e n e f i t s . s t o p ( t r u e ,   t r u e ) ;  
                                                 / *  
                                                 $ c u r r e n t S l i d e B e n e f i t s . a n i m a t e ( {   t o p :   ' - = 4 5 0 '   } ,   " s l o w " ,   f u n c t i o n ( )   {  
                                                 $ ( t h i s ) . c s s ( ' t o p ' ,   ' 4 0 0 p x ' ) ;  
                                                 } ) ;  
                                                 * /  
                                                 $ c u r r e n t S l i d e B e n e f i t s . a n i m a t e ( {   t o p :   ' + = 3 5 0 '   } ,   " s l o w " ,   f u n c t i o n ( )   {  
                                                         $ ( t h i s ) . c s s ( ' t o p ' ,   ' 4 0 0 p x ' ) ;  
                                                 } ) . d e q u e u e ( ) ;  
                                                 $ c u r r e n t S l i d e . f a d e O u t ( 1 0 0 0 ,   f u n c t i o n ( )   {  
                                                         $ p r e v S l i d e . f a d e I n ( 5 0 0 ,  
                                                                                 f u n c t i o n ( )   {  
                                                                                         / / $ p r e v S l i d e B e n e f i t s . a n i m a t e ( {   t o p :   ' - = 3 5 0 '   } ) ;  
                                                                                         c u r r e n t S l i d e I n d e x   =   c u r r e n t S l i d e I n d e x   -   1 ;  
                                                                                         s l i d e r . c h e c k P a g i n g C l a s s ( ) ;  
                                                                                         $ p r e v S l i d e B e n e f i t s . c s s ( ' t o p ' ,   ' - 4 0 0 p x ' ) . a n i m a t e ( {   t o p :   ' + = 4 5 0 '   } ,   " s l o w " ,   f u n c t i o n ( )   {  
                                                                                                 $ p r e v S l i d e . a d d C l a s s ( ' c u r r e n t ' ) ;  
                                                                                         } ) . d e q u e u e ( ) ;  
                                                                                 } ) ;  
                                                 } ) . r e m o v e C l a s s ( ' c u r r e n t ' ) ;  
                                         }  
                                 } ,  
                                 n e x t :   f u n c t i o n ( )   {  
                                         i f   ( o . a u t o S l i d e s h o w )   {  
                                                 c l e a r I n t e r v a l ( u ) ;  
                                                 u   =   n u l l ;  
                                                 s l i d e r . s t o p ( ) ;  
                                         }  
                                         s l i d e r . m o v e F w d ( ) ;  
                                         i f   ( o . a u t o S l i d e s h o w )   {  
                                                 u   =   s e t T i m e o u t ( f u n c t i o n ( )   {   s l i d e r . s t a r t ( ) ;   } ,   t i m e o u t M i l i S e c o n d ) ;  
                                         }  
                                 } ,  
                                 m o v e F w d :   f u n c t i o n ( )   {  
                                         i f   ( c u r r e n t S l i d e I n d e x   +   1   <   t o t a l S l i d e s )   {  
                                                 / / c o n s o l e . l o g ( ' m o v e F w d ' ) ;  
                                                 v a r   $ c u r r e n t S l i d e   =   $ s l i d e s . e q ( c u r r e n t S l i d e I n d e x ) ,  
                                                         $ c u r r e n t S l i d e B e n e f i t s   =   $ c u r r e n t S l i d e . f i n d ( ' . b e n e f i t s ' ) ,  
                                                         $ n e x t S l i d e   =   $ s l i d e s . e q ( c u r r e n t S l i d e I n d e x   +   1 ) ,  
                                                         $ n e x t S l i d e B e n e f i t s   =   $ n e x t S l i d e . f i n d ( ' . b e n e f i t s ' ) ;  
                                                 $ s l i d e s . s t o p ( t r u e ,   t r u e ) ;  
                                                 $ b e n e f i t s . s t o p ( t r u e ,   t r u e ) ;  
                                                 $ c u r r e n t S l i d e B e n e f i t s . a n i m a t e ( {   t o p :   ' - = 4 5 0 '   } ,   " s l o w " ,   f u n c t i o n ( )   {  
                                                         $ ( t h i s ) . c s s ( ' t o p ' ,   ' 4 0 0 p x ' ) ;  
                                                 } ) . d e q u e u e ( ) ;  
                                                 $ c u r r e n t S l i d e . f a d e O u t ( 1 0 0 0 ,   f u n c t i o n ( )   {  
                                                         $ n e x t S l i d e . f a d e I n ( 5 0 0 ,  
                                                                 f u n c t i o n ( )   {  
                                                                         c u r r e n t S l i d e I n d e x   =   c u r r e n t S l i d e I n d e x   +   1 ;  
                                                                         s l i d e r . c h e c k P a g i n g C l a s s ( ) ;  
                                                                         $ n e x t S l i d e B e n e f i t s . a n i m a t e ( {   t o p :   ' - = 3 5 0 '   } ,   " s l o w " ,   f u n c t i o n ( )   {  
                                                                                 $ n e x t S l i d e . a d d C l a s s ( ' c u r r e n t ' ) ;  
                                                                         } ) . d e q u e u e ( ) ;  
                                                                 } ) ;  
                                                 } ) . r e m o v e C l a s s ( ' c u r r e n t ' ) ;  
                                         }  
                                 } ,  
                                 s t a r t O v e r :   f u n c t i o n ( )   {  
                                         / / c o n s o l e . l o g ( ' s t a r t O v e r ' ) ;  
                                         v a r   $ c u r r e n t S l i d e   =   $ s l i d e s . e q ( c u r r e n t S l i d e I n d e x ) ,  
                                                 $ c u r r e n t S l i d e B e n e f i t s   =   $ c u r r e n t S l i d e . f i n d ( ' . b e n e f i t s ' ) ,  
                                                 $ n e x t S l i d e   =   $ s l i d e s . e q ( 0 ) ,  
                                                 $ n e x t S l i d e B e n e f i t s   =   $ n e x t S l i d e . f i n d ( ' . b e n e f i t s ' ) ;  
                                         $ s l i d e s . s t o p ( t r u e ,   t r u e ) ;  
                                         $ b e n e f i t s . s t o p ( t r u e ,   t r u e ) ;  
                                         $ c u r r e n t S l i d e B e n e f i t s . a n i m a t e ( {   t o p :   ' - = 4 5 0 '   } ,   " s l o w " ,   f u n c t i o n ( )   {  
                                                 $ ( t h i s ) . c s s ( ' t o p ' ,   ' 4 0 0 p x ' ) ;  
                                         } ) . d e q u e u e ( ) ;  
                                         $ c u r r e n t S l i d e . f a d e O u t ( 1 0 0 0 ,   f u n c t i o n ( )   {  
                                                 $ n e x t S l i d e . f a d e I n ( 5 0 0 ,  
                                                         f u n c t i o n ( )   {  
                                                                 c u r r e n t S l i d e I n d e x   =   0  
                                                                 s l i d e r . c h e c k P a g i n g C l a s s ( ) ;  
                                                                 $ n e x t S l i d e B e n e f i t s . a n i m a t e ( {   t o p :   ' - = 3 5 0 '   } ,   " s l o w " ,   f u n c t i o n ( )   {  
                                                                         $ n e x t S l i d e . a d d C l a s s ( ' c u r r e n t ' ) ;  
                                                                 } ) . d e q u e u e ( ) ;  
                                                         } ) ;  
                                         } ) . r e m o v e C l a s s ( ' c u r r e n t ' ) ;  
                                 } ,  
                                 c h e c k P a g i n g C l a s s :   f u n c t i o n ( )   {  
                                         / / c o n s o l e . l o g ( c u r r e n t S l i d e I n d e x ) ;  
                                         i f   ( c u r r e n t S l i d e I n d e x   = =   0 )   {  
                                                 $ p r e v S l i d e . a d d C l a s s ( ' d i s a b l e d ' ) ;  
                                                 $ n e x t S l i d e . r e m o v e C l a s s ( ' d i s a b l e d ' ) ;  
                                         }  
                                         e l s e   i f   ( c u r r e n t S l i d e I n d e x   = =   t o t a l S l i d e s   -   1 )   {  
                                                 $ p r e v S l i d e . r e m o v e C l a s s ( ' d i s a b l e d ' ) ;  
                                                 $ n e x t S l i d e . a d d C l a s s ( ' d i s a b l e d ' ) ;  
                                         }  
                                         e l s e   {  
                                                 $ p r e v S l i d e . r e m o v e C l a s s ( ' d i s a b l e d ' ) ;  
                                                 $ n e x t S l i d e . r e m o v e C l a s s ( ' d i s a b l e d ' ) ;  
                                         }  
                                 } ,  
                                 s t a r t :   f u n c t i o n ( )   {  
                                         c l e a r I n t e r v a l ( u ) ;  
                                         u   =   n u l l ;  
                                         t   =   s e t I n t e r v a l ( f u n c t i o n ( )   {   s l i d e r . a u t o P l a y ( ) ;   } ,   t i m e o u t M i l i S e c o n d ) ;  
                                 } ,  
                                 a u t o P l a y :   f u n c t i o n ( )   {  
                                         i f   ( c u r r e n t S l i d e I n d e x   +   1   <   t o t a l S l i d e s )   {  
                                                 s l i d e r . m o v e F w d ( ) ;  
                                         }  
                                         e l s e   {  
                                                 s l i d e r . s t a r t O v e r ( ) ;  
                                         }  
                                 } ,  
                                 s t o p :   f u n c t i o n ( )   {  
                                         / / c o n s o l e . l o g ( ' s t o p ' ) ;  
                                         c l e a r I n t e r v a l ( u ) ;  
                                         c l e a r I n t e r v a l ( t ) ;  
                                         t   =   n u l l ;  
                                 }  
                         } ;   / / s l i d e r  
  
                         s l i d e r . i n i t ( ) ;  
  
                         $ p r e v S l i d e . c l i c k ( f u n c t i o n ( )   {  
                                 i f   ( $ ( t h i s ) . h a s C l a s s ( ' d i s a b l e d ' ) )   {   }  
                                 e l s e   {  
                                         s l i d e r . p r e v ( ) ;  
                                         $ ( t h i s ) . a d d C l a s s ( ' d i s a b l e d ' ) ;  
                                 }  
                                 r e t u r n   f a l s e ;  
                         } ) ;  
  
                         $ n e x t S l i d e . c l i c k ( f u n c t i o n ( )   {  
                                 i f   ( $ ( t h i s ) . h a s C l a s s ( ' d i s a b l e d ' ) )   {   }  
                                 e l s e   {  
                                         s l i d e r . n e x t ( ) ;  
                                         $ ( t h i s ) . a d d C l a s s ( ' d i s a b l e d ' ) ;  
                                 }  
                                 r e t u r n   f a l s e ;  
                         } ) ;  
  
                 } ) ;   / / e a c h  
         } ;   / / e n d   f n  
  
         $ . f n . s l i d e s h o w S l i d e r . d e f a u l t s   =   {  
                 s l i d e r :   ' # s l i d e s h o w ' ,  
                 p a g e r :   ' # s l i d e s h o w P a g e r ' ,  
                 p r e v :   ' # p r e v S l i d e ' ,  
                 n e x t :   ' # n e x t S l i d e ' ,  
                 a u t o S l i d e s h o w :   t r u e ,  
                 t i m e o u t M i l i S e c o n d :   8 0 0 0  
         } ;  
  
 } ) ( j Q u e r y ) ;  
  
 $ ( d o c u m e n t ) . r e a d y ( f u n c t i o n ( )   {  
  
         / / * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * / /  
         / /   C O M M O N   S T U F F  
         / / * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * / /  
  
         / / h o m e p a g e   f l a s h          
         / *  
         $ ( " . t H o m e p a g e M a g n e t i t e   . h o m e p a g e F l a s h   h 1 " ) . f l a s h (  
         {   w i d t h :   ' 1 0 0 % ' ,   h e i g h t :   3 8 8 ,   a u t o p l a y :   t r u e ,   w m o d e :   ' t r a n s p a r e n t '   } ,  
         { } ,  
         f u n c t i o n ( h t m l O p t i o n s )   {  
         $ t h i s   =   $ ( t h i s ) ;  
         h t m l O p t i o n s . s r c   =   " / f l a s h / h e r o . s w f " ;   / / c h a n g e   m e ! !  
         $ t h i s . b e f o r e ( $ . f n . f l a s h . t r a n s f o r m ( h t m l O p t i o n s ) ) ;  
         }  
         ) ;  
         * /  
         $ ( ' # h o m e p a g e H e r o ' ) . s l i d e s h o w S l i d e r ( ) ;  
  
         $ ( ' # s l i d e s h o w   l i   . b e n e f i t s   . t i l e ' ) . h o v e r (  
                 f u n c t i o n ( )   {                          
                         i f   ( $ ( t h i s ) . h a s C l a s s ( ' l a s t ' ) )   {   $ ( t h i s ) . a d d C l a s s ( ' l a s t H o v e r ' ) ;   }  
                         e l s e   {   $ ( t h i s ) . a d d C l a s s ( ' t i l e H o v e r ' ) ;   }  
                 } ,  
                 f u n c t i o n ( )   {  
                         $ ( t h i s ) . r e m o v e C l a s s ( ' l a s t H o v e r ' ) . r e m o v e C l a s s ( ' t i l e H o v e r ' ) ;  
                 }  
         ) ;  
  
         / / i n s t a l l a t i o n   f l a s h          
         $ ( " . f l a s h I n s t a l l a t i o n " ) . f l a s h (  
 	         {   w i d t h :   6 4 0 ,   h e i g h t :   3 4 0 ,   a u t o p l a y :   t r u e ,   w m o d e :   ' t r a n s p a r e n t '   } ,  
 	         { } ,  
 	         f u n c t i o n ( h t m l O p t i o n s )   {  
 	                 $ t h i s   =   $ ( t h i s ) ;  
 	                 h t m l O p t i o n s . s r c   =   " / T h e m e s / M a g n e t i t e / w i n d o w - i n s t a l l a t i o n . s w f " ;   / / c h a n g e   m e ! !  
 	                 $ t h i s . b e f o r e ( $ . f n . f l a s h . t r a n s f o r m ( h t m l O p t i o n s ) ) ;  
 	         }  
         ) ;  
  
         / / i n s t a l l a t i o n   f l a s h          
         $ ( " . v i d e o D e m o " ) . f l a s h (  
 	         {   w i d t h :   5 0 0 ,   h e i g h t :   3 7 5 ,   a u t o p l a y :   t r u e ,   w m o d e :   ' t r a n s p a r e n t '   } ,  
 	         { } ,  
 	         f u n c t i o n ( h t m l O p t i o n s )   {  
 	                 $ t h i s   =   $ ( t h i s ) ;  
 	                 h t m l O p t i o n s . s r c   =   " / T h e m e s / M a g n e t i t e / m a g n e t i t e - v i d e o . s w f " ;  
 	                 $ t h i s . b e f o r e ( $ . f n . f l a s h . t r a n s f o r m ( h t m l O p t i o n s ) ) ;  
 	         }  
         ) ;  
  
         / / d e f a u l t   n a v   d r o p   d o w n   -   s e l e c t   i F r a m e   f i x 	  
         v a r   h a c k I E   =   $ . b r o w s e r . m s i e   & &   ( $ . b r o w s e r . v e r s i o n   <   7 ) ;  
  
         / / d e f a u l t   n a v   h o v e r  
         $ ( " . t e m p l a t e M a g n e t i t e   . d e f a u l t N a v   l i . p a r e n t " ) . h o v e r (  
                 f u n c t i o n ( )   {  
                         v a r   t h i s S u b N a v   =   $ ( t h i s ) . f i n d ( " . d e f a u l t S u b N a v " ) ;  
                         $ ( t h i s ) . a d d C l a s s ( " h o v e r " ) ;  
                         s l i d e T o g g l e ( $ ( t h i s S u b N a v ) ,   t r u e ) ;  
                 } ,  
                 f u n c t i o n ( )   {  
                         v a r   t h i s S u b N a v   =   $ ( t h i s ) . f i n d ( " . d e f a u l t S u b N a v " ) ;  
                         i f   ( h a c k I E )   {   $ ( t h i s ) . f i n d ( " i f r a m e " ) . r e m o v e ( ) ;   }  
                         s l i d e T o g g l e ( $ ( t h i s S u b N a v ) ,   f a l s e ) ;  
                         $ ( t h i s ) . r e m o v e C l a s s ( " h o v e r " ) ;  
                 }  
         ) ;  
         $ ( " . t e m p l a t e M a g n e t i t e   . d e f a u l t N a v   l i . p a r e n t : l a s t - c h i l d " ) . h o v e r (  
                 f u n c t i o n ( )   {   $ ( " . t e m p l a t e M a g n e t i t e   . d e f a u l t N a v " ) . a d d C l a s s ( " d e f a u l t N a v L a s t C h i l d H o v e r e d " ) ;   } ,  
                 f u n c t i o n ( )   {   $ ( " . t e m p l a t e M a g n e t i t e   . d e f a u l t N a v " ) . r e m o v e C l a s s ( " d e f a u l t N a v L a s t C h i l d H o v e r e d " ) ;   }  
         ) ;  
         $ ( " . t e m p l a t e M a g n e t i t e   . d e f a u l t N a v   a " ) . f o c u s ( f u n c t i o n ( )   {   $ ( t h i s ) . b l u r ( ) ;   } ) ;  
  
         / / g a l l e r y   f u n c t i o n s  
         $ ( " . i m a g e S c r e e n   . p r e v I m a g e " ) . c l i c k ( f u n c t i o n ( )   {  
                 v a r   c u r r e n t P o s   =   $ ( " # i m a g e P o s i t i o n " ) . v a l ( ) ;  
                 v a r   n e w P o s   =   N u m b e r ( c u r r e n t P o s )   -   1 ;  
                 i f   ( n e w P o s   < =   0 )   {   n e w P o s   =   0 ;   }  
                 s h o w I m a g e ( n e w P o s ) ;  
         } ) ;  
         $ ( " . i m a g e S c r e e n   . n e x t I m a g e " ) . c l i c k ( f u n c t i o n ( )   {  
                 v a r   c u r r e n t P o s   =   $ ( " # i m a g e P o s i t i o n " ) . v a l ( ) ;  
                 v a r   h i g h e s t P o s   =   $ ( " . s c r o l l a b l e   . i t e m s   l i " ) . l e n g t h   -   1 ;  
                 v a r   n e w P o s   =   N u m b e r ( c u r r e n t P o s )   +   1 ;  
                 i f   ( n e w P o s   > =   h i g h e s t P o s )   {   n e w P o s   =   h i g h e s t P o s ;   }  
                 s h o w I m a g e ( n e w P o s ) ;  
         } ) ;  
         $ ( " . s c r o l l a b l e " ) . s c r o l l a b l e ( {  
                 s i z e :   4 ,   c l i c k a b l e :   f a l s e ,  
                 h o v e r C l a s s :   ' h o v e r '  
         } ) . n a v i g a t o r ( ) ;  
         $ ( " . s c r o l l a b l e   . i t e m s   l i " ) . e a c h ( f u n c t i o n ( i )   {   $ ( t h i s ) . a t t r ( " r e l " ,   i ) ;   } ) ;  
         i f   ( $ ( " . s c r o l l a b l e   . i t e m s   l i " ) . l e n g t h   = =   1 )   {  
                 $ ( " . i m a g e S c r e e n   . n e x t I m a g e " ) . a d d C l a s s ( " d i s a b l e d " ) ;  
         }  
         $ ( " . s c r o l l a b l e   . i t e m s   l i   i m g " ) . b i n d ( " c l i c k " ,   f u n c t i o n ( )   {  
                 v a r   i m g P o s   =   $ ( t h i s ) . p a r e n t ( " l i " ) . a t t r ( " r e l " ) ;  
                 s h o w I m a g e ( i m g P o s ) ;  
         } ) ;  
  
         / / f o r m   v a l i d a t i o n  
         I n i t i a l i z e V a l i d a t i o n ( ) ;  
  
 } ) ;  
  
 f u n c t i o n   I n i t i a l i z e V a l i d a t i o n ( )   {  
         v a r   v a l i d a t o r   =   $ ( " f o r m : f i r s t " ) . b i n d ( " i n v a l i d - f o r m . v a l i d a t e " ,   f u n c t i o n ( )   {   } ) . v a l i d a t e ( {  
                 e r r o r E l e m e n t :   " s p a n " ,  
                 e r r o r P l a c e m e n t :   f u n c t i o n ( e r r o r ,   e l e m e n t )   {  
                         e r r o r . a p p e n d T o ( e l e m e n t . p a r e n t ( ' . f o r m I n p u t ' ) ) ;  
                 } ,  
                 s u c c e s s :   f u n c t i o n ( l a b e l )   { } ,  
                 o n f o c u s o u t :   f u n c t i o n ( e l e m e n t )   {   $ ( e l e m e n t ) . v a l i d ( ) ;   }  
         } ) ;  
 }  
  
 f u n c t i o n   s h o w I m a g e ( i m g P o s )   {  
         v a r   l a r g e I m a g e P a t h   =   $ ( " . s c r o l l a b l e   . i t e m s   l i " ) . e q ( i m g P o s ) . f i n d ( " i m g " ) . a t t r ( " s r c " ) . r e p l a c e ( " _ 1 0 0 x 7 5 . " ,   " _ 4 6 0 x 3 4 5 . " ) ;  
         $ ( " # l a r g e r V i e w " ) . h t m l ( " " ) ;  
         v a r   l a r g e r I m a g e   =   n e w   I m a g e ( ) ;  
         $ ( l a r g e r I m a g e )  
                 . l o a d ( f u n c t i o n ( )   {  
                         $ ( t h i s ) . h i d e ( ) ;  
                         $ ( " # l a r g e r V i e w " ) . a p p e n d ( t h i s ) ;  
                         $ ( t h i s ) . f a d e I n ( ) ;  
                         $ ( " # i m a g e P o s i t i o n " ) . v a l ( i m g P o s ) ;  
                         d i s a b l e P r e v N e x t I m a g e B u t t o n s ( ) ;  
                 } )  
                 . e r r o r ( f u n c t i o n ( )   {  
                         / /   n o t i f y   t h e   u s e r   t h a t   t h e   i m a g e   c o u l d   n o t   b e   l o a d e d  
                         $ ( " # l a r g e r V i e w " ) . a p p e n d ( " I m a g e   n o t   f o u n d " ) ;  
                 } )  
                 . a t t r ( ' s r c ' ,   l a r g e I m a g e P a t h ) ;  
 }  
  
 f u n c t i o n   d i s a b l e P r e v N e x t I m a g e B u t t o n s ( )   {  
         v a r   c u r r e n t P o s   =   $ ( " # i m a g e P o s i t i o n " ) . v a l ( ) ;  
         v a r   h i g h e s t P o s   =   $ ( " . s c r o l l a b l e   . i t e m s   l i " ) . l e n g t h   -   1  
         i f   ( h i g h e s t P o s   = =   0 )   {  
                 $ ( " . i m a g e S c r e e n   . p r e v I m a g e ,   . i m a g e S c r e e n   . n e x t I m a g e " ) . a d d C l a s s ( " d i s a b l e d " ) ;                  
         }  
         e l s e   {  
                 i f   ( c u r r e n t P o s   < =   0 )   {  
                         $ ( " . i m a g e S c r e e n   . p r e v I m a g e " ) . a d d C l a s s ( " d i s a b l e d " ) ;  
                         $ ( " . i m a g e S c r e e n   . n e x t I m a g e " ) . r e m o v e C l a s s ( " d i s a b l e d " ) ;  
                 }  
                 e l s e   i f   ( c u r r e n t P o s   > =   h i g h e s t P o s )   {  
                         $ ( " . i m a g e S c r e e n   . p r e v I m a g e " ) . r e m o v e C l a s s ( " d i s a b l e d " ) ;  
                         $ ( " . i m a g e S c r e e n   . n e x t I m a g e " ) . a d d C l a s s ( " d i s a b l e d " ) ;  
                 }  
                 e l s e   {  
                         $ ( " . i m a g e S c r e e n   . p r e v I m a g e ,   . i m a g e S c r e e n   . n e x t I m a g e " ) . r e m o v e C l a s s ( " d i s a b l e d " ) ;                          
                 }  
         }  
 }  
  
 / /   t h i s   i s   a   f i x   f o r   t h e   j Q u e r y   s l i d e   e f f e c t s  
 f u n c t i o n   s l i d e T o g g l e ( e l ,   b S h o w )   {  
         v a r   $ e l   =   $ ( e l ) ,   h e i g h t   =   $ e l . d a t a ( " o r i g i n a l H e i g h t " ) ,   v i s i b l e   =   $ e l . i s ( " : v i s i b l e " ) ;  
         i f   ( a r g u m e n t s . l e n g t h   = =   1 )   b S h o w   =   ! v i s i b l e ;  
         i f   ( b S h o w   = =   v i s i b l e )   r e t u r n   f a l s e ;  
         i f   ( ! h e i g h t )   {  
                 h e i g h t   =   $ e l . s h o w ( ) . h e i g h t ( ) ;  
                 $ e l . d a t a ( " o r i g i n a l H e i g h t " ,   h e i g h t ) ;  
                 i f   ( ! v i s i b l e )   $ e l . h i d e ( ) . c s s ( {   h e i g h t :   0   } ) ;  
         }  
         i f   ( b S h o w )   {   $ e l . s h o w ( ) . a n i m a t e ( {   h e i g h t :   h e i g h t   } ,   {   d u r a t i o n :   2 5 0   } ) ;   }  
         e l s e   {   $ e l . a n i m a t e ( {   h e i g h t :   0   } ,   {   d u r a t i o n :   2 5 0 ,   c o m p l e t e :   f u n c t i o n ( )   {   $ e l . h i d e ( ) ;   }   } ) ;   }  
 }  
 f u n c t i o n   t r a c k E n q u i r y ( e v e n t ,   a c t i o n )   {  
         v a r   m y d o m a i n   =   w i n d o w . l o c a t i o n . h o s t n a m e ;  
         v a r   p a g e T r a c k e r   = ' ' ;  
         i f   ( m y d o m a i n   = =   ' w w w . m a g n e t i t e . c o m . a u ' )   {  
                 p a g e T r a c k e r     =   _ g a t . _ g e t T r a c k e r ( " U A - 1 6 6 1 8 3 3 3 - 1 " ) ;  
         }  
         e l s e   {  
                 p a g e T r a c k e r   =   _ g a t . _ g e t T r a c k e r ( " U A - 1 6 6 1 8 3 3 3 - 2 " ) ;  
         }          
        
         p a g e T r a c k e r . _ i n i t D a t a ( ) ;  
         p a g e T r a c k e r . _ t r a c k P a g e v i e w ( ) ;  
         p a g e T r a c k e r . _ t r a c k E v e n t ( e v e n t ,   a c t i o n ) ;  
 }  
  
 
