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

Unified Diff: pkg/analyzer_experimental/bin/formatter.dart

Issue 25290002: Format selection preservation editor bits. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 3 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
« no previous file with comments | « editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/DartEditor.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer_experimental/bin/formatter.dart
===================================================================
--- pkg/analyzer_experimental/bin/formatter.dart (revision 28056)
+++ pkg/analyzer_experimental/bin/formatter.dart (working copy)
@@ -159,7 +159,11 @@
_toJson(formatResult) =>
// Actual JSON format TBD
JSON.encode({'source': formatResult.source,
- 'selection': formatResult.selection.toString()});
+ 'selection': {
+ 'offset': formatResult.selection.offset,
+ 'length': formatResult.selection.length
+ }
+ });
/// Log the given [msg].
_log(String msg) {
« no previous file with comments | « editor/tools/plugins/com.google.dart.tools.ui/src/com/google/dart/tools/ui/internal/text/editor/DartEditor.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698