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

Unified Diff: sdk/lib/svg/dartium/svg_dartium.dart

Issue 1292963003: Fix identity and SVGAnimatedString issues with element_classes_test (Closed) Base URL: git@github.com:dart-lang/sdk.git@integration
Patch Set: Created 5 years, 4 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: sdk/lib/svg/dartium/svg_dartium.dart
diff --git a/sdk/lib/svg/dartium/svg_dartium.dart b/sdk/lib/svg/dartium/svg_dartium.dart
index 9a42f14febcc42546db25d90eb97a64c5aab60be..ca19fdd7ee6b591d5a5b930bba45a79874164635 100644
--- a/sdk/lib/svg/dartium/svg_dartium.dart
+++ b/sdk/lib/svg/dartium/svg_dartium.dart
@@ -7018,6 +7018,17 @@ class SvgElement extends Element implements GlobalEventHandlers {
var e = new SvgElement.tag(tag);
return e is SvgElement && !(e is UnknownElement);
}
+
+ String get className => _svgClassName.baseVal;
+
+ // Unbelievable hack. We can't create an SvgAnimatedString, but we can get
+ // the existing one and change its baseVal.
+ // TODO(alanknight): Handle suppressing the SVGAnimated<*> better
+ set className(String s) {
+ var oldClass = _svgClassName;
+ oldClass.baseVal = s;
+ super.className = oldClass;
+ }
// To suppress missing implicit constructor warnings.
factory SvgElement._() { throw new UnsupportedError("Not supported"); }

Powered by Google App Engine
This is Rietveld 408576698