public void SaveWorkSpace() { if (_currentFilePath != null) { SaveThread saveThread = new SaveThread(Shapes, Lines, _currentFilePath); saveThread.Start(); UndoRedo.ChangeSinceSave = false; StatusText = "File: \"" + _currentFilePath + "\" Saved successfully"; } else { SaveAsWorkSpace(); StatusText = "File: \"" + _currentFilePath + "\" Saved successfully"; } }
public void SaveAsWorkSpace() { SaveFileDialog save = new SaveFileDialog(); save.DefaultExt = ".scumle"; save.Filter = "(.scumle)|*.scumle"; if (save.ShowDialog() == true) { _currentFilePath = Path.GetFullPath(save.FileName); SaveThread saveThread = new SaveThread(Shapes, Lines, _currentFilePath); saveThread.Start(); UndoRedo.ChangeSinceSave = false; } StatusText = "File: \"" + _currentFilePath + "\" Saved successfully"; }