Author: akazakov
Date: 2008-11-06 08:35:23 -0500 (Thu, 06 Nov 2008)
New Revision: 11577
Modified:
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamCoreValidator.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-3106 Changed error marker. It is better to mark
field name only.
Modified:
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamCoreValidator.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamCoreValidator.java 2008-11-06
13:10:05 UTC (rev 11576)
+++
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamCoreValidator.java 2008-11-06
13:35:23 UTC (rev 11577)
@@ -624,7 +624,11 @@
if(variables==null || variables.size()<1) {
// Injection has unknown name. Mark it.
IResource declarationResource = declaration.getResource();
- addError(UNKNOWN_VARIABLE_NAME_MESSAGE_ID, SeamPreferences.UNKNOWN_VARIABLE_NAME, new
String[]{name}, bijection, declarationResource);
+ ISeamTextSourceReference nameRef = getNameLocation(bijection);
+ if(nameRef == null) {
+ nameRef = bijection;
+ }
+ addError(UNKNOWN_VARIABLE_NAME_MESSAGE_ID, SeamPreferences.UNKNOWN_VARIABLE_NAME, new
String[]{name}, nameRef, declarationResource);
}
}
}