public void Add(Entry item) { var itemHash = item.GetHashCode(); foreach (FATabStripItem fatab in faTabStrip1.Items) { if (Convert.ToInt32(fatab.Tag) == itemHash) { faTabStrip1.SelectedItem = fatab; return; } } _storedEntries.Add(itemHash, item); var tab = new FATabStripItem { Tag = itemHash, Title = string.Format("[{0}] {1}", item.Category, item.Name) }; tab.Controls.Add(new EntryEditor(item) { Name = "EntryEditor", Dock = DockStyle.Fill }); faTabStrip1.AddTab(tab, true); }
public bool Remove(Entry item) { return _storedEntries.Remove(item.GetHashCode()); }