private void ApplyRules(StyleCopAddIn addIn, TreeNode parentNode)
 {
     foreach (TreeNode node in parentNode.Nodes)
     {
         Rule tag = node.Tag as Rule;
         if (tag == null)
         {
             this.ApplyRules(addIn, node);
         }
         else
         {
             addIn.SetSetting(this.tabControl.LocalSettings, new BooleanProperty(addIn, tag.Name + "#Enabled", node.Checked));
         }
     }
 }
        /// <summary>
        /// Applies settings for rules under the given node.
        /// </summary>
        /// <param name="addIn">The addin owning the rules.</param>
        /// <param name="parentNode">The parent node of the rules.</param>
        private void ApplyRules(StyleCopAddIn addIn, TreeNode parentNode)
        {
            Param.AssertNotNull(addIn, "addIn");
            Param.AssertNotNull(parentNode, "parentNode");

            foreach (TreeNode node in parentNode.Nodes)
            {
                Rule rule = node.Tag as Rule;
                if (rule == null)
                {
                    this.ApplyRules(addIn, node);
                }
                else
                {
                    addIn.SetSetting(
                        this.tabControl.LocalSettings,
                        new BooleanProperty(addIn, rule.Name + "#Enabled", node.Checked));
                }
            }
        }
 private void ApplyProperties(StyleCopAddIn addIn)
 {
     ICollection<BooleanProperty> is2 = null;
     if (this.properties.TryGetValue(addIn, out is2))
     {
         foreach (BooleanProperty property in is2)
         {
             addIn.SetSetting(this.tabControl.LocalSettings, property);
         }
     }
 }
        /// <summary>
        /// Applies the properties for the given add-in.
        /// </summary>
        /// <param name="addIn">The add-in.</param>
        private void ApplyProperties(StyleCopAddIn addIn)
        {
            Param.AssertNotNull(addIn, "addIn");

            ICollection<BooleanProperty> addInProperties = null;

            if (this.properties.TryGetValue(addIn, out addInProperties))
            {
                foreach (BooleanProperty property in addInProperties)
                {
                    addIn.SetSetting(this.tabControl.LocalSettings, property);
                }
            }
        }