public void ValidateFields() { string content = fileNameInputfield.text; bool isValid = true; if (content == string.Empty) { DisplayError(fileNameInputfield, "Field required"); isValid = false; } if (content.Contains(".txt")) { DisplayError(fileNameInputfield, "Remove the extension"); isValid = false; } if (isValid) { DisplayError(fileNameInputfield); TabsEditorManager inst = TabsEditorManager.standalone; if (inst == null) { return; } inst.CreateNewTabs(content); } }
public void OnTrackSelected() { TabsEditorManager inst = TabsEditorManager.standalone; if (inst == null) { return; } inst.CreateNewTabs(TrackName); }