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

Side by Side Diff: runtime/observatory/lib/src/elements/script_inset.dart

Issue 1393523002: Support tab completion of line:col in the debugger. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: edits Created 5 years, 2 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library script_inset_element; 5 library script_inset_element;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:html'; 8 import 'dart:html';
9 import 'observatory_element.dart'; 9 import 'observatory_element.dart';
10 import 'service_ref.dart'; 10 import 'service_ref.dart';
(...skipping 407 matching lines...) Expand 10 before | Expand all | Expand 10 after
418 void _onDebugEvent(event) { 418 void _onDebugEvent(event) {
419 if (script == null) { 419 if (script == null) {
420 return; 420 return;
421 } 421 }
422 switch (event.kind) { 422 switch (event.kind) {
423 case ServiceEvent.kBreakpointAdded: 423 case ServiceEvent.kBreakpointAdded:
424 case ServiceEvent.kBreakpointResolved: 424 case ServiceEvent.kBreakpointResolved:
425 case ServiceEvent.kBreakpointRemoved: 425 case ServiceEvent.kBreakpointRemoved:
426 var loc = event.breakpoint.location; 426 var loc = event.breakpoint.location;
427 if (loc.script == script) { 427 if (loc.script == script) {
428 int line = script.tokenToLine(loc.tokenPos); 428 int line;
429 if (loc.tokenPos != null) {
430 line = script.tokenToLine(loc.tokenPos);
431 } else {
432 line = script.tokenToLine(loc.line);
433 }
429 if ((line >= _startLine) && (line <= _endLine)) { 434 if ((line >= _startLine) && (line <= _endLine)) {
430 _updateTask.queue(); 435 _updateTask.queue();
431 } 436 }
432 } 437 }
433 break; 438 break;
434 default: 439 default:
435 // Ignore. 440 // Ignore.
436 break; 441 break;
437 } 442 }
438 } 443 }
(...skipping 574 matching lines...) Expand 10 before | Expand all | Expand 10 after
1013 @CustomTag('source-inset') 1018 @CustomTag('source-inset')
1014 class SourceInsetElement extends PolymerElement { 1019 class SourceInsetElement extends PolymerElement {
1015 SourceInsetElement.created() : super.created(); 1020 SourceInsetElement.created() : super.created();
1016 1021
1017 @published SourceLocation location; 1022 @published SourceLocation location;
1018 @published String height = null; 1023 @published String height = null;
1019 @published int currentPos; 1024 @published int currentPos;
1020 @published bool inDebuggerContext = false; 1025 @published bool inDebuggerContext = false;
1021 @published ObservableList variables; 1026 @published ObservableList variables;
1022 } 1027 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698