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

Unified Diff: sdk/lib/html/dart2js/html_dart2js.dart

Issue 1242063002: Restore workaround for old Chrome bug that also affects Safari and in some cases Firefox, fix test … (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 5 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:
Download patch
« no previous file with comments | « no previous file | sdk/lib/html/dartium/html_dartium.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/html/dart2js/html_dart2js.dart
diff --git a/sdk/lib/html/dart2js/html_dart2js.dart b/sdk/lib/html/dart2js/html_dart2js.dart
index 4cc90adf80c4289040b1e2ac95d471843299d79c..0f15bdc72da26e478431c5f3d4952544ce9a94b9 100644
--- a/sdk/lib/html/dart2js/html_dart2js.dart
+++ b/sdk/lib/html/dart2js/html_dart2js.dart
@@ -13181,6 +13181,12 @@ abstract class Element extends Node implements GlobalEventHandlers, ParentNode,
if (_parseDocument == null) {
_parseDocument = document.implementation.createHtmlDocument('');
_parseRange = _parseDocument.createRange();
+
+ // Workaround for Safari bug. Was also previously Chrome bug 229142
+ // - URIs are not resolved in new doc.
+ var base = _parseDocument.createElement('base');
+ base.href = document.baseUri;
+ _parseDocument.head.append(base);
}
var contextElement;
if (this is BodyElement) {
« no previous file with comments | « no previous file | sdk/lib/html/dartium/html_dartium.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698