public void Load(byte[] pbXspFile) { XspArchive a = new XspArchive(); a.Load(pbXspFile); foreach (KeyValuePair <string, byte[]> kvp in a.Items) { string str = GetID(kvp.Key); ImageArchiveItem it = new ImageArchiveItem(kvp.Key, kvp.Value); Debug.Assert(!m_dItems.ContainsKey(str)); m_dItems[str] = it; } }
public void Load(byte[] pbXspFile) { XspArchive a = new XspArchive(); a.Load(pbXspFile); foreach(KeyValuePair<string, byte[]> kvp in a.Items) { string str = GetID(kvp.Key); ImageArchiveItem it = new ImageArchiveItem(kvp.Key, kvp.Value); Debug.Assert(!m_dItems.ContainsKey(str)); m_dItems[str] = it; } }
private static int CompareByName(ImageArchiveItem a, ImageArchiveItem b) { if(a == null) { Debug.Assert(false); return -1; } if(b == null) { Debug.Assert(false); return 1; } return string.Compare(a.Name, b.Name, StrUtil.CaseIgnoreCmp); }