Author: akazakov
Date: 2012-01-24 17:51:41 -0500 (Tue, 24 Jan 2012)
New Revision: 38123
Modified:
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/ca/AbstractELCompletionEngine.java
trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/WebContent/varAttributes.xhtml
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/SeamValidatorsTest.java
Log:
https://issues.jboss.org/browse/JBIDE-10699
Modified:
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/ca/AbstractELCompletionEngine.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/ca/AbstractELCompletionEngine.java 2012-01-24
21:59:52 UTC (rev 38122)
+++
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/ca/AbstractELCompletionEngine.java 2012-01-24
22:51:41 UTC (rev 38123)
@@ -334,8 +334,12 @@
var.resolveValue("#{" + var.getElToken().getText() + suffix +
"}"); //$NON-NLS-1$ //$NON-NLS-2$
// Save all used variables from "value" EL to the list of used variables
for EL which uses this "var" attribute.
- for (ELSegment segment : varELResolution.getSegments()) {
- firstSegment.getVariables().addAll(segment.getVariables());
+ if(firstSegment.getVariables()!=null) {
+ for (ELSegment segment : varELResolution.getSegments()) {
+ if(segment.getVariables()!=null) {
+ firstSegment.getVariables().addAll(segment.getVariables());
+ }
+ }
}
ELResolutionImpl oldElResolution = resolveELOperand(file, operand,
returnEqualedVariablesOnly, false, offset);
Modified:
trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/WebContent/varAttributes.xhtml
===================================================================
---
trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/WebContent/varAttributes.xhtml 2012-01-24
21:59:52 UTC (rev 38122)
+++
trunk/seam/tests/org.jboss.tools.seam.core.test/projects/SeamWebWarTestProject/WebContent/varAttributes.xhtml 2012-01-24
22:51:41 UTC (rev 38123)
@@ -52,10 +52,5 @@
<h:dataTable value="#{setItems}" var="value">
<h:outputText value="#{value.nonExistingBroken}"/>
</h:dataTable>
-
- <h:dataTable value="#{nonExistingBroken}" var="valueBroken">
- <h:outputText value="#{valueBroken.name}"/>
- </h:dataTable>
-
</ui:define>
</ui:composition>
\ No newline at end of file
Modified:
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/SeamValidatorsTest.java
===================================================================
---
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/SeamValidatorsTest.java 2012-01-24
21:59:52 UTC (rev 38122)
+++
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/SeamValidatorsTest.java 2012-01-24
22:51:41 UTC (rev 38123)
@@ -139,9 +139,7 @@
TestUtil.validate(file);
String messagePattern =
MessageFormat.format(ELValidationMessages.UNKNOWN_EL_VARIABLE_PROPERTY_NAME, new
Object[]{"nonExistingBroken"});
- AbstractResourceMarkerTest.assertMarkerIsCreated(file, messagePattern, false, 49, 50,
53, 56, 57);
List<IMarker> markers = getMarkersByGroupName(file,
SeamValidationErrorManager.MARKED_SEAM_PROJECT_MESSAGE_GROUP);
-
StringBuffer sb = new StringBuffer("Here is a list of found markers in
").append(file.getFullPath().toOSString()).append(markers.size()==0?" : [":
" : [\r\n"); //$NON-NLS-1$ //$NON-NLS-2$");
int i = 0;
for (IMarker marker : markers) {
@@ -153,7 +151,8 @@
i++;
}
sb.append("]"); //$NON-NLS-1$
- assertEquals(sb.toString(), 2, markers.size());
+ System.out.println(sb.toString());
+ AbstractResourceMarkerTest.assertMarkerIsCreated(file, messagePattern, false, 49, 50,
53);
}
private List<IMarker> getMarkersByGroupName(IResource resource, String
messageGroup) throws CoreException {