Exemplo n.º 1
0
 private void MergeHtmlElements(PredefinedRuleSet existing, IRule rule)
 {
     foreach (Declaration newDecelearion in rule.Declarations)
     {
         existing.MergeDeceleration(newDecelearion);
     }
 }
Exemplo n.º 2
0
        private bool TryGetHtmlElementClass(IDictionary <string, IRule> classes, string selector, out PredefinedRuleSet existing)
        {
            IEnumerable <IRule> q = from r in classes.Values
                                    where r.RuleType == RuleType.PredefinedRuleSet && r.Selector == selector
                                    select r;

            existing = (PredefinedRuleSet)q.SingleOrDefault();
            return(existing != null);
        }