public FormWorkbench(DockPanel dockPanel) { InitializeComponent(); ReloadDockPanel(dockPanel); IXExplorerDictionary explorers = ApplicationRuntime.Explorers; foreach (KeyValuePair <ResourceStruct.ResourceType, ResourceStruct.ResInfo> kvp in ResourceStruct.OrderedListNames) { IXExplorer explorer = explorers[kvp.Key]; ToolStripMenuItem tsmi = explorer.NewToolStripMenuItem(); tsmi.Click += new System.EventHandler(this.ToolStripMenuItem_Click); if (kvp.Value.isCommon) { this.explorersMenu.DropDownItems.Add(tsmi); } else { this.infrequentTSMI.DropDownItems.Add(tsmi); } this.explorersMenu.DropDownItems.Add(this.infrequentTSMI); } }
private static void InitializeInfinityFiles() { chitinIndex = new ChitinIndex(appPaths.ChitinKeyFile); talkIndex = new TalkIndex(appPaths.TalkRefFile); explorers = new IXExplorerDictionary(chitinIndex.CkeyDictionary); }
private void showCommonTSMI_Click(object sender, EventArgs e) { IXExplorerDictionary explorers = ApplicationRuntime.Explorers; foreach (KeyValuePair <ResourceStruct.ResourceType, ResourceStruct.ResInfo> kvp in ResourceStruct.OrderedListNames) { if (kvp.Value.isCommon) { explorers[kvp.Key].Form.Show(dockPanel); } } }