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

Unified Diff: tools/dom/scripts/systemhtml.py

Issue 1832713002: Optimize dartium dart:html bindings so real world application performance is acceptable. Improves d… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 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: tools/dom/scripts/systemhtml.py
diff --git a/tools/dom/scripts/systemhtml.py b/tools/dom/scripts/systemhtml.py
index 672d97e7a1faaed2eda62a1fd0b2b10ea104d85f..7d997eed2370e587bcae9dba57e1385bf4c7d783 100644
--- a/tools/dom/scripts/systemhtml.py
+++ b/tools/dom/scripts/systemhtml.py
@@ -586,7 +586,7 @@ class HtmlDartInterfaceGenerator(object):
class_modifiers = ''
else:
# For Dartium w/ JsInterop these suppressed interfaces are needed to
- # instanciate the internal classes when wrap_jso is called for a JS object.
+ # instanciate the internal classes.
if (self._renamer.ShouldSuppressInterface(self._interface) and
not(isinstance(self._backend, Dart2JSBackend)) and
self._options.dart_js_interop):
@@ -600,13 +600,6 @@ class HtmlDartInterfaceGenerator(object):
class_name = self._interface_type_info.implementation_name()
- js_interop_equivalence_op = \
- ' bool operator ==(other) => unwrap_jso(other) == unwrap_jso(this) || identical(this, other);\n' \
- + ' int get hashCode => unwrap_jso(this).hashCode;\n'
- # ClientRect overrides the equivalence operator.
- if interface_name == 'ClientRect' or interface_name == 'DomRectReadOnly':
- js_interop_equivalence_op = ''
-
js_interop_wrapper = '''
@Deprecated("Internal Use Only")
@@ -633,8 +626,7 @@ class HtmlDartInterfaceGenerator(object):
@Deprecated("Internal Use Only")
{0}.internal_() {{ }}
-
-{1}'''.format(class_name, js_interop_equivalence_op)
+'''.format(class_name)
# Change to use the synthesized class so we can construct with a mixin
# classes prefixed with name of NativeFieldWrapperClass2 don't have a
# default constructor so classes with mixins can't be new'd.

Powered by Google App Engine
This is Rietveld 408576698