private static void ExtractResources(ResourceDirectoryEntry root, byte[] buf) { ByteReader br = new ByteReader(buf, 0, buf.Length); while (br.Length >= 32) { br.Align(4); RESOURCEHEADER hdr = new RESOURCEHEADER(br); if (hdr.DataSize != 0) { root[hdr.TYPE][hdr.NAME][new OrdinalOrName(hdr.LanguageId)].Data = ByteBuffer.Wrap(br.ReadBytes(hdr.DataSize)); } } }
internal void ExtractResources(byte[] buf) { ByteReader br = new ByteReader(buf, 0, buf.Length); while (br.Length >= 32) { br.Align(4); RESOURCEHEADER hdr = new RESOURCEHEADER(br); if (hdr.DataSize != 0) { root[hdr.TYPE][hdr.NAME][new OrdinalOrName(hdr.LanguageId)].Data = ByteBuffer.Wrap(br.ReadBytes(hdr.DataSize)); } } }