int selectionOffset= selection.getOffset();
int selectionEndOffset= selectionOffset + selection.getLength();
List edits= new LinkedList();
- ITypedRegion partition= docExtension.getPartition(IPHPPartitions.PHP_PARTITIONING, selectionOffset);
+ ITypedRegion partition= docExtension.getPartition(IPHPPartitions.PHP_PARTITIONING, selectionOffset, false);
handleFirstPartition(partition, edits, factory, selectionOffset);
boolean wasJavadoc= false; // true if the previous partition is javadoc
- if (partType == IPHPPartitions.PHP_MULTILINE_COMMENT) {
+ if (partType == IPHPPartitions.PHP_PHPDOC_COMMENT) {
wasJavadoc= true;
}
// advance to next partition
- partition= docExtension.getPartition(IPHPPartitions.PHP_PARTITIONING, partEndOffset);
+ partition= docExtension.getPartition(IPHPPartitions.PHP_PARTITIONING, partEndOffset, false);
partType= partition.getType();
// start of next partition
} else { // !wasJavadoc
- if (partType == IPHPPartitions.PHP_MULTILINE_COMMENT) {
+ if (partType == IPHPPartitions.PHP_PHPDOC_COMMENT) {
// if next is javadoc, end block comment before
edits.add(factory.createEdit(partition.getOffset(), 0, getCommentEnd()));
// } else if (partType == IJavaPartitions.JAVA_MULTI_LINE_COMMENT) {
private boolean isSpecialPartition(String partType) {
return// partType == IPHPPartitions.PHP_CHARACTER
//||
- partType == IPHPPartitions.PHP_STRING;
+ partType == IPHPPartitions.PHP_STRING_DQ;
//|| partType == IPHPPartitions.PHP_SINGLE_LINE_COMMENT;
}