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

Issue 10447091: Cleanup NodeSelectors. (Closed)

Created:
8 years, 6 months ago by podivilov
Modified:
8 years, 6 months ago
Reviewers:
Anton Muhin, sra1, Jacob
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Cleanup NodeSelectors. Currently, query and queryAll methods generation in dart:html is somehow affected by a combination of the following factors: 1) Document, DocumentFragment, and Element are declared to inherit from NodeSelector interface in dart.idl 2) NodeSelector methods for some of these interfaces are present in_private_html_members, but not all, resulting in generation of $dom_* variants 3) querySelector is renamed to query via _html_library_renames for all interfaces except for Document 4) Some of these methods and their private variants have custom implementations in impl_*.darttemplate's This patch aims to simplify that logic. R=jacobr@google.com,sra@google.com Committed: https://code.google.com/p/dart/source/detail?r=8240

Patch Set 1 #

Total comments: 6

Patch Set 2 : Address comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+47 lines, -70 lines) Patch
M lib/dom/scripts/systemhtml.py View 1 5 chunks +3 lines, -5 lines 0 comments Download
M lib/dom/scripts/systemnative.py View 1 1 chunk +6 lines, -11 lines 0 comments Download
M lib/dom/templates/html/impl/impl_Document.darttemplate View 2 chunks +2 lines, -10 lines 0 comments Download
M lib/dom/templates/html/impl/impl_DocumentFragment.darttemplate View 1 chunk +2 lines, -0 lines 0 comments Download
M lib/dom/templates/html/impl/impl_Element.darttemplate View 1 chunk +2 lines, -0 lines 0 comments Download
M lib/dom/templates/html/interface/interface_Element.darttemplate View 1 1 chunk +0 lines, -6 lines 0 comments Download
M lib/html/dartium/html_dartium.dart View 12 chunks +17 lines, -19 lines 0 comments Download
M lib/html/frog/html_frog.dart View 12 chunks +15 lines, -19 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
podivilov
8 years, 6 months ago (2012-05-30 19:31:15 UTC) #1
Anton Muhin
STV! http://codereview.chromium.org/10447091/diff/1/lib/dom/idl/dart/dart.idl File lib/dom/idl/dart/dart.idl (left): http://codereview.chromium.org/10447091/diff/1/lib/dom/idl/dart/dart.idl#oldcode37 lib/dom/idl/dart/dart.idl:37: // Force NodeSelector. WebKit defines these operations directly. ...
8 years, 6 months ago (2012-05-31 18:20:44 UTC) #2
podivilov
8 years, 6 months ago (2012-06-04 09:34:36 UTC) #3
http://codereview.chromium.org/10447091/diff/1/lib/dom/idl/dart/dart.idl
File lib/dom/idl/dart/dart.idl (left):

http://codereview.chromium.org/10447091/diff/1/lib/dom/idl/dart/dart.idl#oldc...
lib/dom/idl/dart/dart.idl:37: // Force NodeSelector. WebKit defines these
operations directly.
On 2012/05/31 18:20:44, antonmuhin wrote:
> why remove it from here?

Reverted.

http://codereview.chromium.org/10447091/diff/1/lib/dom/idl/dart/dart.idl#oldc...
lib/dom/idl/dart/dart.idl:44: Element implements NodeSelector;
On 2012/05/31 18:20:44, antonmuhin wrote:
> I can see that Element explicitly says it inherits from NodeSelector.  Where
> Document and DocumentFragment are marked as inheriting from NodeSelector?

Document and DocumentFragment interfaces extend NodeSelector. But I think it's
better to revert this change as well.

http://codereview.chromium.org/10447091/diff/1/lib/dom/templates/html/interfa...
File lib/dom/templates/html/interface/interface_Element.darttemplate (right):

http://codereview.chromium.org/10447091/diff/1/lib/dom/templates/html/interfa...
lib/dom/templates/html/interface/interface_Element.darttemplate:40: interface
NodeSelector {
On 2012/05/31 18:20:44, antonmuhin wrote:
> I'd rather keep this interface in dart.idl.  Ditto for other interfaces in
this
> file.

Done.

Powered by Google App Engine
This is Rietveld 408576698