private void mnuOpen_Click(object sender, EventArgs e) { if (CheckForChanges()) { return; } OpenFileDialog ofd = new OpenFileDialog(); ofd.Filter = "FlowSharp (*.fsd)|*.fsd"; DialogResult res = ofd.ShowDialog(); if (res == DialogResult.OK) { filename = ofd.FileName; } else { return; } IFlowSharpCanvasService canvasService = serviceManager.Get <IFlowSharpCanvasService>(); canvasService.LoadDiagrams(filename); UpdateCaption(); UpdateMru(filename); }
private void OnRecentFileSelected(object sender, EventArgs e) { if (CheckForChanges()) { return; } ToolStripItem tsi = sender as ToolStripItem; filename = tsi.Text; IFlowSharpCanvasService canvasService = serviceManager.Get <IFlowSharpCanvasService>(); canvasService.LoadDiagrams(filename); UpdateCaption(); }