[jbosstools-commits] JBoss Tools SVN: r43409 - trunk/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/contentassist/computers.

jbosstools-commits at lists.jboss.org jbosstools-commits at lists.jboss.org
Wed Sep 5 07:27:34 EDT 2012


Author: vrubezhny
Date: 2012-09-05 07:27:34 -0400 (Wed, 05 Sep 2012)
New Revision: 43409

Modified:
   trunk/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/contentassist/computers/XmlELCompletionProposalComputer.java
Log:
JBIDE-12441 
Wrong cursor position after using code assist for EL with '[]' 

Issue is fixed

Modified: trunk/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/contentassist/computers/XmlELCompletionProposalComputer.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/contentassist/computers/XmlELCompletionProposalComputer.java	2012-09-05 09:45:05 UTC (rev 43408)
+++ trunk/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/contentassist/computers/XmlELCompletionProposalComputer.java	2012-09-05 11:27:34 UTC (rev 43409)
@@ -269,7 +269,7 @@
 				if (restOfValue.indexOf(']') != -1) {
 					cursorPosition += restOfValue.indexOf(']') + 1;
 				}
-			} else {
+			} else if (replacementString.lastIndexOf('.') < replacementString.lastIndexOf(']')) {
 				cursorPosition = replacementString.indexOf(']') + 1;
 			}
 			if (prefix.isAttributeValue() && prefix.hasOpenQuote() && !prefix.hasCloseQuote()) {



More information about the jbosstools-commits mailing list