From 6b56762f8b0b7c67734fa6e83da9cf9002c407d9 Mon Sep 17 00:00:00 2001 From: Alex Harui Date: Mon, 26 Mar 2018 23:02:20 -0700 Subject: [PATCH] include htmlelement type selectors in output --- .../driver/js/royale/JSCSSCompilationSession.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/compiler-jx/src/main/java/org/apache/royale/compiler/internal/driver/js/royale/JSCSSCompilationSession.java b/compiler-jx/src/main/java/org/apache/royale/compiler/internal/driver/js/royale/JSCSSCompilationSession.java index e2e30860c..5790aae5d 100644 --- a/compiler-jx/src/main/java/org/apache/royale/compiler/internal/driver/js/royale/JSCSSCompilationSession.java +++ b/compiler-jx/src/main/java/org/apache/royale/compiler/internal/driver/js/royale/JSCSSCompilationSession.java @@ -506,6 +506,14 @@ protected boolean keepRule(ICSSRule newRule) if (!sp.contains("defaults.css")) return true; + // might need to loop over all selectors in selector group + if (newRule.getSelectorGroup().size() > 0) + { + String elementName = newRule.getSelectorGroup().get(0).getElementName(); + if (elementName != null) + if (htmlElementNames.contains(elementName)) + return true; + } return false; }