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