| Index: editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightings.java
|
| diff --git a/editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightings.java b/editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightings.java
|
| index a8237c85205516450984caaee0001f583743cd7e..4dc3cf1627e5af14ebd0f24cb182c5e42f8fe99d 100644
|
| --- a/editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightings.java
|
| +++ b/editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightings.java
|
| @@ -16,6 +16,7 @@ package com.google.dart.tools.ui.internal.text.editor;
|
| import com.google.common.collect.ImmutableList;
|
| import com.google.common.collect.Lists;
|
| import com.google.dart.compiler.ast.DartBinaryExpression;
|
| +import com.google.dart.compiler.ast.DartCatchBlock;
|
| import com.google.dart.compiler.ast.DartClass;
|
| import com.google.dart.compiler.ast.DartDoubleLiteral;
|
| import com.google.dart.compiler.ast.DartExportDirective;
|
| @@ -32,6 +33,7 @@ import com.google.dart.compiler.ast.DartNode;
|
| import com.google.dart.compiler.ast.DartPartOfDirective;
|
| import com.google.dart.compiler.ast.DartSourceDirective;
|
| import com.google.dart.compiler.ast.DartStringLiteral;
|
| +import com.google.dart.compiler.ast.DartTryStatement;
|
| import com.google.dart.compiler.ast.DartTypeNode;
|
| import com.google.dart.compiler.ast.DartVariable;
|
| import com.google.dart.compiler.ast.ImportCombinator;
|
| @@ -144,6 +146,18 @@ public class SemanticHighlightings {
|
| implementsOffset,
|
| "implements".length()));
|
| }
|
| + // try {} on
|
| + if (node instanceof DartTryStatement) {
|
| + List<SourceRange> onTokens = Lists.newArrayList();
|
| + DartTryStatement onStatement = (DartTryStatement) node;
|
| + for (DartCatchBlock catchBlock : onStatement.getCatchBlocks()) {
|
| + int onOffset = catchBlock.getOnTokenOffset();
|
| + if (onOffset != -1) {
|
| + onTokens.add(SourceRangeFactory.forStartLength(onOffset, "on".length()));
|
| + }
|
| + }
|
| + return onTokens;
|
| + }
|
| // done
|
| return result;
|
| }
|
|
|