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

Side by Side Diff: pkg/analysis_server/lib/src/services/refactoring/rename.dart

Issue 640253004: Fix for renaming import without an import prefix. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | pkg/analysis_server/test/edit/refactoring_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 services.src.refactoring.rename; 5 library services.src.refactoring.rename;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'package:analysis_server/src/protocol_server.dart' hide Element; 9 import 'package:analysis_server/src/protocol_server.dart' hide Element;
10 import 'package:analysis_server/src/services/correction/source_range.dart'; 10 import 'package:analysis_server/src/services/correction/source_range.dart';
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 bool requiresPreview() { 178 bool requiresPreview() {
179 return false; 179 return false;
180 } 180 }
181 181
182 static String _getDisplayName(Element element) { 182 static String _getDisplayName(Element element) {
183 if (element is ImportElement) { 183 if (element is ImportElement) {
184 PrefixElement prefix = element.prefix; 184 PrefixElement prefix = element.prefix;
185 if (prefix != null) { 185 if (prefix != null) {
186 return prefix.displayName; 186 return prefix.displayName;
187 } 187 }
188 return '';
188 } 189 }
189 return element.displayName; 190 return element.displayName;
190 } 191 }
191 } 192 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analysis_server/test/edit/refactoring_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698