public static ClipActionRecord ReadClipActionRecord(this ISwfStreamReader reader, byte swfVersion) { var record = new ClipActionRecord(); record.Flags = reader.ReadClipEventFlags(swfVersion); if (record.Flags.IsEmpty) { return(record); } var offset = reader.ReadUInt32(); if (record.Flags.ClipEventKeyPress) { record.KeyCode = reader.ReadByte(); } ActionBase action; var ar = new ActionReader(reader); do { action = ar.ReadAction(); record.Actions.Add(action); } while (!(action is ActionEnd)); return(record); }
public static void ReadClipActions(this ISwfStreamReader reader, byte swfVersion, ClipActionsList clipActions) { clipActions.Reserved = reader.ReadUInt16(); clipActions.Flags = reader.ReadClipEventFlags(swfVersion); reader.ReadClipActionRecords(swfVersion, clipActions.Records); }