Author: vrubezhny
Date: 2008-12-05 10:37:41 -0500 (Fri, 05 Dec 2008)
New Revision: 12312
Modified:
trunk/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/contentassist/FaceletsHtmlContentAssistProcessor.java
Log:
JBIDE-3341 The wrong labels are shown in the Facelets' content assistant
The labels are fixed
Modified:
trunk/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/contentassist/FaceletsHtmlContentAssistProcessor.java
===================================================================
---
trunk/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/contentassist/FaceletsHtmlContentAssistProcessor.java 2008-12-05
14:43:54 UTC (rev 12311)
+++
trunk/jst/plugins/org.jboss.tools.jst.jsp/src/org/jboss/tools/jst/jsp/contentassist/FaceletsHtmlContentAssistProcessor.java 2008-12-05
15:37:41 UTC (rev 12312)
@@ -246,6 +246,15 @@
Image image = kbProposal.hasImage() ? kbProposal.getImage() :
JspEditorPlugin.getDefault().getImage(JspEditorPlugin.CA_JSF_EL_IMAGE_PATH);
+ if (!replacementString.startsWith("#{") &&
!replacementString.startsWith("${")) {
+ if (label.startsWith("#") ||
label.startsWith("$"))
+ label = label.substring(1);
+ if (label.startsWith("{"))
+ label = label.substring(1);
+ if (label.endsWith("}"))
+ label = label.substring(0, label.length() - 1);
+ }
+
AutoContentAssistantProposal proposal = new
AutoContentAssistantProposal(kbProposal.autoActivationContentAssistantAfterApplication(),
replacementString,
replacementBeginPosition, replacementLength, cursorPosition,
image,
@@ -281,6 +290,15 @@
Image image = kbProposal.hasImage() ? kbProposal.getImage() :
JspEditorPlugin.getDefault().getImage(JspEditorPlugin.CA_JSF_EL_IMAGE_PATH);
+ if (!replacementString.startsWith("#{") &&
!replacementString.startsWith("${")) {
+ if (label.startsWith("#") ||
label.startsWith("$"))
+ label = label.substring(1);
+ if (label.startsWith("{"))
+ label = label.substring(1);
+ if (label.endsWith("}"))
+ label = label.substring(0, label.length() - 1);
+ }
+
AutoContentAssistantProposal proposal = new
AutoContentAssistantProposal(kbProposal.autoActivationContentAssistantAfterApplication(),
replacementString,
replacementBeginPosition, replacementLength, cursorPosition,
image,
Show replies by date