Exemplo n.º 1
0
        public async Task <OvrStreamTitle[]> GetTitles()
        {
            Title[] titles = await this.connection.GetTitlesAsync(CancellationToken.None);

            List <OvrStreamTitle> results = new List <OvrStreamTitle>();

            foreach (Title title in titles)
            {
                OvrStreamTitle newTitle = new OvrStreamTitle
                {
                    Name = title.Name,
                };

                List <OvrStreamVariable> variables = new List <OvrStreamVariable>();
                foreach (Variable variable in title.Variables)
                {
                    OvrStreamVariable newVariable = new OvrStreamVariable
                    {
                        Name  = variable.Name,
                        Value = variable.Value,
                    };

                    variables.Add(newVariable);
                }

                newTitle.Variables = variables.ToArray();
                results.Add(newTitle);
            }

            return(results.ToArray());
        }
Exemplo n.º 2
0
        private void SelectIntellisenseTitle()
        {
            this.shouldShowIntellisense = false;
            OvrStreamTitle title = TitleNameIntellisenseListBox.SelectedItem as OvrStreamTitle;

            if (title != null)
            {
                this.TitleNameTextBox.Text       = title.Name;
                this.TitleNameTextBox.CaretIndex = this.TitleNameTextBox.Text.Length;
            }
            this.shouldShowIntellisense = true;

            HideTitleIntellisense();
        }