コード例 #1
0
    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);
        }
    }
コード例 #2
0
    public void OnTrackSelected()
    {
        TabsEditorManager inst = TabsEditorManager.standalone;

        if (inst == null)
        {
            return;
        }

        inst.CreateNewTabs(TrackName);
    }