Recurity.Swf.ClipActionRecord.Write C# (CSharp) Method

Write() public method

public Write ( Stream output ) : void
output Stream
return void
        public void Write( Stream output )
        {
            long pos = output.Position;

            _ClipEventFlags.Write( output );

            UInt32 actionRecordSize = _Code.Length;
            // HACK: increase this value to cause Flash Player 10 to crash when handling the ClipAction
            actionRecordSize += (uint)( _ClipEventFlags.ClipEventKeyPress ? 1 : 0 ); // optional KeyCode

            BinaryWriter bw = new BinaryWriter( output );
            bw.Write( actionRecordSize );

            if ( _ClipEventFlags.ClipEventKeyPress )
                bw.Write( _KeyCode );

            for ( int i = 0; i < _Code.Count; i++ )
            {
                _Code[ i ].Write( output );
            }

               //Log.Debug(this,  ( ( ulong )( output.Position - pos ) ).ToString( "d" ) + " bytes written, " + this.Length + " calculated" );
        }