Exemple #1
0
        public TextBoxUIFullModel(
            string text = null,

            string speaker              = null,
            bool?auto                   = false,
            SoundEffectScriptable tone  = null,
            float?crawlTime             = null,
            bool?closeWhenDone          = false,
            int?toneIntervalMax         = null,
            List <string> proceedInputs = null
            )
            : base(speaker, auto, tone, crawlTime, closeWhenDone, toneIntervalMax, proceedInputs)
        {
            Text = text;
        }
Exemple #2
0
 public TextBoxUIPartialModel(
     string speaker              = "",
     bool?auto                   = false,
     SoundEffectScriptable tone  = null,
     float?crawlTime             = null,
     bool?closeWhenDone          = false,
     int?toneIntervalMax         = null,
     List <string> proceedInputs = null
     )
 {
     Speaker         = speaker;
     Auto            = auto;
     Tone            = tone;
     CrawlTime       = crawlTime ?? PerformanceContent.DefaultCrawlTime;
     CloseWhenDone   = closeWhenDone;
     ToneIntervalMax = toneIntervalMax;
     ProceedInputs   = proceedInputs;
 }
Exemple #3
0
        /// <summary>
        /// Provide new model and execute.
        /// </summary>
        public async Task ExecuteAsync(TextBoxUIFullModel model)
        {
            if (model.Text != null)
            {
                Text = model.Text;
            }

            if (model.Speaker != null)
            {
                Speaker = model.Speaker;
            }

            if (model.Auto != null)
            {
                Auto = model.Auto == true;
            }

            if (model.CrawlTime != null)
            {
                CrawlTime = model.CrawlTime.Value;
            }

            if (model.Tone)
            {
                Tone = model.Tone;
            }

            if (model.CloseWhenDone != null)
            {
                CloseWhenDone = model.CloseWhenDone == true;
            }

            if (model.ToneIntervalMax != null)
            {
                ToneIntervalMax = model.ToneIntervalMax.Value;
            }

            if (model.ProceedInputs != null)
            {
                ProceedInputs = model.ProceedInputs;
            }

            await ExecuteAsync();
        }