示例#1
0
		public MacroItem(string settingString)
		{
			Label = "";
			string[] s = settingString.Split(ListSeparator);

			List<string> _list = new List<string>(s);

			if (_list.Count == 0) { return; } // Empty list, nothing to do - leave defaults from above.

			// If we get here, we have at least 1 element. That's our label.
			Label = _list[0];
			_list.RemoveAt(0);

			CommandList = MarlinStringHelpers.SanitizeCommandList(_list);
		}
示例#2
0
		public MacroItem(string label, List<String> commandList)
		{
			Label = label;
			CommandList = MarlinStringHelpers.SanitizeCommandList(commandList);
		}