Esempio n. 1
0
        private void EditMacroCommand()
        {
            if (listViewMacro.SelectedItems.Count != 1)
            {
                return;
            }

            ListViewItem selected = listViewMacro.SelectedItems[0];

            string  selectedTag = selected.Tag as string;
            Command command     = Processor.CreateCommand(selectedTag);

            if (_commandProcessor.Edit(command, this))
            {
                selected.Text = command.GetUserDisplayText();
                selected.Tag  = command.ToString();
            }
        }