Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(323)

Unified Diff: editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightingReconciler.java

Issue 9651004: Make SourceInfo a class, rename its menthods. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Tweak for formatting, lazily create LainesInfo Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightingReconciler.java
diff --git a/editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightingReconciler.java b/editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightingReconciler.java
index 75bd40d0b54512881e0588e4b6d8669c0777509b..f923fe18ec076d548ef5f8124e3889e84f426bd6 100644
--- a/editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightingReconciler.java
+++ b/editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/SemanticHighlightingReconciler.java
@@ -13,13 +13,13 @@
*/
package com.google.dart.tools.ui.internal.text.editor;
+import com.google.dart.compiler.ast.ASTVisitor;
import com.google.dart.compiler.ast.DartBooleanLiteral;
import com.google.dart.compiler.ast.DartDoubleLiteral;
import com.google.dart.compiler.ast.DartExpression;
import com.google.dart.compiler.ast.DartIdentifier;
import com.google.dart.compiler.ast.DartIntegerLiteral;
import com.google.dart.compiler.ast.DartNode;
-import com.google.dart.compiler.ast.ASTVisitor;
import com.google.dart.compiler.ast.DartUnit;
import com.google.dart.tools.core.model.DartElement;
import com.google.dart.tools.ui.DartToolsPlugin;
@@ -76,8 +76,8 @@ public class SemanticHighlightingReconciler implements IDartReconcilingListener,
for (int i = 0, n = fJobSemanticHighlightings.length; i < n; i++) {
SemanticHighlighting semanticHighlighting = fJobSemanticHighlightings[i];
if (fJobHighlightings[i].isEnabled() && semanticHighlighting.consumes(fToken)) {
- int offset = node.getSourceStart();
- int length = node.getSourceLength();
+ int offset = node.getSourceInfo().getOffset();
+ int length = node.getSourceInfo().getLength();
if (offset > -1 && length > 0) {
addPosition(offset, length, fJobHighlightings[i]);
}
@@ -154,8 +154,8 @@ public class SemanticHighlightingReconciler implements IDartReconcilingListener,
for (int i = 0, n = fJobSemanticHighlightings.length; i < n; i++) {
SemanticHighlighting semanticHighlighting = fJobSemanticHighlightings[i];
if (fJobHighlightings[i].isEnabled() && semanticHighlighting.consumesLiteral(fToken)) {
- int offset = node.getSourceStart();
- int length = node.getSourceLength();
+ int offset = node.getSourceInfo().getOffset();
+ int length = node.getSourceInfo().getLength();
if (offset > -1 && length > 0) {
addPosition(offset, length, fJobHighlightings[i]);
}

Powered by Google App Engine
This is Rietveld 408576698