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

Issue 24294002: Dartium changes for custom element lifecycle events. (Closed)

Created:
7 years, 3 months ago by blois
Modified:
7 years, 3 months ago
Reviewers:
vsm, siva
CC:
reviews+dom_dartlang.org
Visibility:
Public.

Description

Dartium changes for custom element lifecycle events. These changes bring us to parity with the current behavior but using the proper custom element infrastructure. Next steps are to hook up the rest of the lifecycle events and transition to the constructor for created. BUG= R=vsm@google.com Committed: https://src.chromium.org/viewvc/multivm?view=rev&revision=1383

Patch Set 1 #

Total comments: 8

Patch Set 2 : #

Patch Set 3 : merge with ToT #

Patch Set 4 : #

Total comments: 11
Unified diffs Side-by-side diffs Delta from patch set Stats (+726 lines, -356 lines) Patch
D Source/bindings/dart/DartCustomElement.h View 1 2 1 chunk +0 lines, -74 lines 0 comments Download
D Source/bindings/dart/DartCustomElement.cpp View 1 2 1 chunk +0 lines, -142 lines 0 comments Download
A + Source/bindings/dart/DartCustomElementBinding.h View 1 1 chunk +12 lines, -9 lines 2 comments Download
A + Source/bindings/dart/DartCustomElementBinding.cpp View 1 chunk +8 lines, -5 lines 0 comments Download
A + Source/bindings/dart/DartCustomElementConstructorBuilder.h View 1 chunk +25 lines, -35 lines 2 comments Download
A Source/bindings/dart/DartCustomElementConstructorBuilder.cpp View 1 1 chunk +130 lines, -0 lines 0 comments Download
A + Source/bindings/dart/DartCustomElementLifecycleCallbacks.h View 1 1 chunk +14 lines, -21 lines 0 comments Download
A Source/bindings/dart/DartCustomElementLifecycleCallbacks.cpp View 1 1 chunk +177 lines, -0 lines 0 comments Download
A + Source/bindings/dart/DartCustomElementWrapper.h View 1 chunk +16 lines, -11 lines 0 comments Download
A Source/bindings/dart/DartCustomElementWrapper.cpp View 1 2 1 chunk +133 lines, -0 lines 0 comments Download
M Source/bindings/dart/DartDOMData.h View 5 chunks +9 lines, -5 lines 0 comments Download
M Source/bindings/dart/DartDOMData.cpp View 1 chunk +20 lines, -0 lines 0 comments Download
M Source/bindings/dart/DartDOMWrapper.h View 1 2 4 chunks +6 lines, -9 lines 0 comments Download
M Source/bindings/dart/DartDOMWrapper.cpp View 1 2 2 chunks +0 lines, -9 lines 0 comments Download
M Source/bindings/dart/DartNativeUtilities.cpp View 1 2 6 chunks +46 lines, -21 lines 0 comments Download
M Source/bindings/dart/DartUtilities.h View 3 chunks +3 lines, -1 line 0 comments Download
M Source/bindings/dart/DartUtilities.cpp View 1 2 chunks +22 lines, -0 lines 1 comment Download
M Source/bindings/dart/custom/DartDocumentCustom.cpp View 1 2 2 chunks +86 lines, -0 lines 4 comments Download
M Source/bindings/dart/gyp/overrides.gypi View 1 chunk +8 lines, -2 lines 0 comments Download
M Source/bindings/dart/gyp/scripts/massage_factories.py View 1 2 2 chunks +3 lines, -5 lines 2 comments Download
M Source/bindings/v8/CustomElementConstructorBuilder.h View 1 chunk +8 lines, -7 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
blois
7 years, 3 months ago (2013-09-19 22:25:54 UTC) #1
vsm
nice! lgtm with comments Note: asiva refactored the create code to split out lookup and ...
7 years, 3 months ago (2013-09-19 23:12:26 UTC) #2
blois
https://chromiumcodereview.appspot.com/24294002/diff/1/Source/bindings/dart/DartCustomElementBinding.h File Source/bindings/dart/DartCustomElementBinding.h (right): https://chromiumcodereview.appspot.com/24294002/diff/1/Source/bindings/dart/DartCustomElementBinding.h#newcode45 Source/bindings/dart/DartCustomElementBinding.h:45: ~DartCustomElementBinding() { } On 2013/09/19 23:12:26, vsm wrote: > ...
7 years, 3 months ago (2013-09-20 00:10:25 UTC) #3
blois
Committed patchset #4 manually as r1383.
7 years, 3 months ago (2013-09-20 18:30:24 UTC) #4
siva
DBC https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/DartCustomElementBinding.h File Source/bindings/dart/DartCustomElementBinding.h (right): https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/DartCustomElementBinding.h#newcode45 Source/bindings/dart/DartCustomElementBinding.h:45: Dart_Handle customType() { return Dart_HandleFromPersistent(m_customType); } I would ...
7 years, 3 months ago (2013-09-20 20:57:36 UTC) #5
blois
7 years, 3 months ago (2013-09-20 22:18:03 UTC) #6
Message was sent while issue was closed.
Addressed in https://codereview.chromium.org/23513085/

https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/Dart...
File Source/bindings/dart/DartCustomElementBinding.h (right):

https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/Dart...
Source/bindings/dart/DartCustomElementBinding.h:45: Dart_Handle customType() {
return Dart_HandleFromPersistent(m_customType); }
On 2013/09/20 20:57:37, siva wrote:
> I would really like to avoid such implicit conversion of handles from
Persistent
> to regular handles. We should make explicit the places were
> this conversion is necessary and do it there. For instance when
> returning values back to dart it is not necessary to convert a
PersistentHandle.
> 
> This method could be
> Dart_PersistentHandle customType() { return m_customType; }

Done.

https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/Dart...
File Source/bindings/dart/DartCustomElementConstructorBuilder.h (right):

https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/Dart...
Source/bindings/dart/DartCustomElementConstructorBuilder.h:77: Dart_Handle
m_customType;
On 2013/09/20 20:57:37, siva wrote:
> How do we ensure that this handle will not go out of scope before
> DartCustomElementConstructorBuilder is destroyed?

This class is only used as a stack variable from DartNativeUtilities.cpp.

https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/cust...
File Source/bindings/dart/custom/DartDocumentCustom.cpp (right):

https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/cust...
Source/bindings/dart/custom/DartDocumentCustom.cpp:91: Dart_SetReturnValue(args,
DartElement::toDart(result));
On 2013/09/20 20:57:37, siva wrote:
> This is an inefficient way to return stuff, you should use
> DartElement::returnToDart(args, result);

Done.

https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/cust...
Source/bindings/dart/custom/DartDocumentCustom.cpp:135:
Dart_SetReturnValue(args, DartElement::toDart(result));
On 2013/09/20 20:57:37, siva wrote:
> Ditto.

Done.

https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/gyp/...
File Source/bindings/dart/gyp/scripts/massage_factories.py (right):

https://codereview.chromium.org/24294002/diff/13001/Source/bindings/dart/gyp/...
Source/bindings/dart/gyp/scripts/massage_factories.py:98: r'return
DartHTMLUnknownElement::toDart(toHTMLUnknownElement(element));'),
On 2013/09/20 20:57:37, siva wrote:
> if you are creating a new wrapper you should be using createWrapper not
toDart.

Done.

Powered by Google App Engine
This is Rietveld 408576698