X-Git-Url: http://git.phpeclipse.com diff --git a/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/ui/actions/RemoveBlockCommentAction.java b/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/ui/actions/RemoveBlockCommentAction.java index 2af8550..38c0291 100644 --- a/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/ui/actions/RemoveBlockCommentAction.java +++ b/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/ui/actions/RemoveBlockCommentAction.java @@ -30,7 +30,8 @@ import org.eclipse.ui.texteditor.ITextEditor; * @since 3.0 */ public class RemoveBlockCommentAction extends BlockCommentAction { - + final static String DEFAULT_PARTITIONING_CONTENT_TYPE = "__dftl_partition_content_type"; //$NON-NLS-1$ + /** * Creates a new instance. * @@ -54,7 +55,9 @@ public class RemoveBlockCommentAction extends BlockCommentAction { int offset= selection.getOffset(); int endOffset= offset + selection.getLength(); - ITypedRegion partition= docExtension.getPartition(IPHPPartitions.PHP_PARTITIONING, offset, false); +// ITypedRegion partition= docExtension.getPartition(IPHPPartitions.PHP_PARTITIONING, offset, false); + ITypedRegion partition= docExtension.getPartition(IDocumentExtension3.DEFAULT_PARTITIONING, offset, false); + int partOffset= partition.getOffset(); int partEndOffset= partOffset + partition.getLength(); @@ -65,12 +68,15 @@ public class RemoveBlockCommentAction extends BlockCommentAction { edits.add(factory.createEdit(partEndOffset - tokenLength, tokenLength, "")); //$NON-NLS-1$ } - partition= docExtension.getPartition(IPHPPartitions.PHP_PARTITIONING, partEndOffset, false); +// partition= docExtension.getPartition(IPHPPartitions.PHP_PARTITIONING, partEndOffset, false); + partition= docExtension.getPartition(IDocumentExtension3.DEFAULT_PARTITIONING, partEndOffset, false); + partOffset= partition.getOffset(); partEndOffset= partOffset + partition.getLength(); } - if (partition.getType() == IPHPPartitions.PHP_PHPDOC_COMMENT) { +// if (partition.getType() == IPHPPartitions.PHP_PHPDOC_COMMENT) { + if (partition.getType() == DEFAULT_PARTITIONING_CONTENT_TYPE) { edits.add(factory.createEdit(partOffset, tokenLength, "")); //$NON-NLS-1$ edits.add(factory.createEdit(partEndOffset - tokenLength, tokenLength, "")); //$NON-NLS-1$ }