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

Unified Diff: pkg/analyzer/doc/support/dart.js

Issue 1817913002: Generate the task model graph as an HTML file and put it in the doc directory. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Copy support files into local directory Created 4 years, 8 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 | pkg/analyzer/doc/support/style.css » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/doc/support/dart.js
diff --git a/pkg/browser/lib/dart.js b/pkg/analyzer/doc/support/dart.js
similarity index 60%
copy from pkg/browser/lib/dart.js
copy to pkg/analyzer/doc/support/dart.js
index b1f97b1804b6cf57edc33768bcad8523ddb4a23f..f8d686e1ab832e4534b442a34a86ecbaf44f17d6 100644
--- a/pkg/browser/lib/dart.js
+++ b/pkg/analyzer/doc/support/dart.js
@@ -4,8 +4,7 @@
(function() {
// Bootstrap support for Dart scripts on the page as this script.
-// TODO(18463): Remove user agent check. We will remove 'Dart' from there.
-if (!navigator.dartEnabled && (navigator.userAgent.indexOf('(Dart)') === -1)) {
+if (navigator.userAgent.indexOf('(Dart)') === -1) {
// TODO:
// - Support in-browser compilation.
// - Handle inline Dart scripts.
@@ -26,22 +25,6 @@ if (!navigator.dartEnabled && (navigator.userAgent.indexOf('(Dart)') === -1)) {
// than one script.
document.currentScript = script;
parent.replaceChild(script, scripts[i]);
-
- // Support for incremental compilation.
- script.onload = function (event) {
- var script = event.target;
- if (self.$dart_unsafe_incremental_support) {
- new WebSocket(script.src.replace(/^http/, 'ws')).onmessage =
- function (event) {
- var patch = String(event.data);
- self.$dart_unsafe_incremental_support.patch(patch);
- script.dispatchEvent(
- new CustomEvent(
- "dart_program_updated",
- { bubbles: true, detail: { patch: patch } }));
- };
- }
- };
}
}
}
« no previous file with comments | « no previous file | pkg/analyzer/doc/support/style.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698