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

Unified Diff: utils/dartdoc/dartdoc.dart

Issue 9153010: Naming change for code review. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 11 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 | « no previous file | utils/dartdoc/test/dartdoc_tests.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/dartdoc/dartdoc.dart
diff --git a/utils/dartdoc/dartdoc.dart b/utils/dartdoc/dartdoc.dart
index ceeea47d5ec63136ba17fc2a891931cd7540c7c5..4e0f7a6f2cddf29311041df15562cc39ddec25f8 100644
--- a/utils/dartdoc/dartdoc.dart
+++ b/utils/dartdoc/dartdoc.dart
@@ -105,8 +105,8 @@ class Dartdoc {
new md.CodeSyntax(@'\[\:((?:.|\n)*?)\:\]'));
md.setImplicitLinkResolver((name) => resolveNameReference(name,
- currentLibrary: _currentLibrary, currentType: _currentType,
- currentMember: _currentMember));
+ library: _currentLibrary, type: _currentType,
+ member: _currentMember));
}
document(String entrypoint) {
@@ -782,8 +782,8 @@ class Dartdoc {
* brackets. It will try to figure out what the name refers to and link or
* style it appropriately.
*/
- md.Node resolveNameReference(String name, [Member currentMember = null,
- Type currentType = null, Library currentLibrary = null]) {
+ md.Node resolveNameReference(String name, [Member member = null,
+ Type type = null, Library library = null]) {
makeLink(String href) {
final anchor = new md.Element.text('a', name);
anchor.attributes['href'] = relativePath(href);
@@ -806,8 +806,8 @@ class Dartdoc {
}
// See if it's a parameter of the current method.
- if (currentMember != null) {
- for (final parameter in currentMember.parameters) {
+ if (member != null) {
+ for (final parameter in member.parameters) {
if (parameter.name == name) {
final element = new md.Element.text('span', name);
element.attributes['class'] = 'param';
@@ -817,22 +817,22 @@ class Dartdoc {
}
// See if it's another member of the current type.
- if (currentType != null) {
- final member = findMember(currentType);
+ if (type != null) {
+ final member = findMember(type);
if (member != null) {
return makeLink(memberUrl(member));
}
}
// See if it's another type in the current library.
- if (currentLibrary != null) {
- final type = currentLibrary.types[name];
+ if (library != null) {
+ final type = library.types[name];
if (type != null) {
return makeLink(typeUrl(type));
}
// See if it's a top-level member in the current library.
- final member = findMember(currentLibrary.topType);
+ final member = findMember(library.topType);
if (member != null) {
return makeLink(memberUrl(member));
}
« no previous file with comments | « no previous file | utils/dartdoc/test/dartdoc_tests.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698