예제 #1
0
        /// <summary>
        /// Setups the groups.
        /// </summary>
        /// <param name="groups">Groups.</param>
        private void SetupGroups(List<string> groups)
        {
            foreach (string s in groups) {
                cbeGroups.AppendText (s);
            }

            if (!string.IsNullOrEmpty (pinSequence.GroupName) && !string.IsNullOrWhiteSpace (pinSequence.GroupName)) {
                cbeGroups.Active = groups.IndexOf (pinSequence.GroupName);
            }

            cbeGroups.Changed += (object sender, EventArgs e) => {
                if (pinSequence != null) {
                    pinSequence.GroupName = cbeGroups.ActiveText;
                }
            };
        }