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

Unified Diff: utils/apidoc/apidoc.dart

Issue 9319001: Integrate VM IO libraries and search box into apidoc. (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
Index: utils/apidoc/apidoc.dart
diff --git a/utils/apidoc/apidoc.dart b/utils/apidoc/apidoc.dart
index 1c340fc3a5c8576b847b9cf22905a3d41f4be12c..ae9e061eba2b0bee5122bd37236f480e67e9dfe7 100644
--- a/utils/apidoc/apidoc.dart
+++ b/utils/apidoc/apidoc.dart
@@ -30,6 +30,11 @@ void main() {
_diff.run();
world.reset();
+ // TODO(rnystrom): Cram in the the IO libraries. This is hackish right now.
+ // We should probably move corelib stuff completely out of dartdoc and have it
+ // all here.
+ world.getOrAddLibrary('io_libs.dart');
+
print('Generating docs...');
final apidoc = new Apidoc(mdn);
apidoc.document('html');
@@ -65,6 +70,9 @@ class Apidoc extends doc.Dartdoc {
<p><a href="$tos">Terms of Service</a> |
<a href="$privacy">Privacy Policy</a></p>
''';
+
+ searchEngineId = '011220921317074318178:i4mscbaxtru';
+ searchResultsUrl = 'http://www.dartlang.org/search.html';
}
void writeHeadContents(String title) {
@@ -99,6 +107,27 @@ class Apidoc extends doc.Dartdoc {
''');
}
+ void docIndexLibrary(Library library) {
+ // TODO(rnystrom): Hackish. The IO libraries reference this but we don't
+ // want it in the docs.
nweiz 2012/01/31 23:35:33 I dunno if this is even that hackish. It makes sen
Bob Nystrom 2012/02/01 00:35:29 Yeah, it's kind of hairy because if stuff in the i
+ if (library.name == 'dart:nativewrappers') return;
+ super.docIndexLibrary(library);
+ }
+
+ void docLibraryNavigationJson(Library library, Map libraries) {
+ // TODO(rnystrom): Hackish. The IO libraries reference this but we don't
+ // want it in the docs.
+ if (library.name == 'dart:nativewrappers') return;
+ super.docLibraryNavigationJson(library, libraries);
+ }
+
+ void docLibrary(Library library) {
+ // TODO(rnystrom): Hackish. The IO libraries reference this but we don't
+ // want it in the docs.
+ if (library.name == 'dart:nativewrappers') return;
+ super.docLibrary(library);
+ }
+
String getTypeComment(Type type) {
return _mergeDocs(
includeMdnTypeComment(type),

Powered by Google App Engine
This is Rietveld 408576698