Commit Graph

168 Commits

Author SHA1 Message Date
blois@google.com 34f58a8209 Start of dartium custom element lifecycle event support.
These are the Dart repo changes paired with https://codereview.chromium.org/24294002/

BUG=
R=vsm@google.com

Review URL: https://codereview.chromium.org//23817006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@27718 260f80e4-7a28-3924-810f-c04153c831b5
2013-09-20 18:40:11 +00:00
asiva@google.com ca128dea70 - Modify toDart to first do a simple lookup in the appropriate table before going down the templatized
morass of switch statements
- Add a returnToDart function so that the WeakPersistent Handle returned from a lookup/create of the wrapper
  could be returned as is without the need to call Dart_handleFromWeakPersistentHandle
- Use Dart_SetDoubleReturnValue for doubles

some DromaeoDartium numbers before this change:

CONSOLE MESSAGE: RESULT: Dromaeo-drt dartium-dart dom-query getElementsByTagName(div) runs-per-second 84240.6
CONSOLE MESSAGE: RESULT: Dromaeo-drt dartium-dart dom-traverse nextSibling runs-per-second 207.91683326669332
CONSOLE MESSAGE: RESULT: Dromaeo-drt dartium-dart dom-query getElementsByTagName(*) runs-per-second 69599.2

some DromaeoDartium numbers after this change:

CONSOLE MESSAGE: RESULT: Dromaeo-drt dartium-dart dom-query getElementsByTagName(div) runs-per-second 104252.4
CONSOLE MESSAGE: RESULT: Dromaeo-drt dartium-dart dom-traverse nextSibling runs-per-second 366.8
CONSOLE MESSAGE: RESULT: Dromaeo-drt dartium-dart dom-query getElementsByTagName(*) runs-per-second 94922.6

R=rmacnak@google.com, vsm@google.com

Review URL: https://codereview.chromium.org//23681014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@27710 260f80e4-7a28-3924-810f-c04153c831b5
2013-09-20 16:25:12 +00:00
jacobr@google.com 013e3bb062 Dart binding changes to along with Blink merge 155942-156717
BUG=
R=blois@google.com

Review URL: https://codereview.chromium.org//23829002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26948 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-30 21:24:02 +00:00
blois@google.com 87e39090a1 Exposing native doubles as doubles when they are read-only or method return values.
This keeps num for parameters of operations and fields which are settable. Requested because some DOM APIs (such as Performance.now) don't really make sense returning ints.

BUG=11133
R=vsm@google.com

Review URL: https://codereview.chromium.org//21555003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26817 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-28 21:07:13 +00:00
asiva@google.com 4f6536ba66 Use new Dart API functions
Dart_GetNativeIntegerArgument
Dart_GetNativeBooleanArgument
Dart_GetNativeDoubleArgument

R=vsm@google.com

Review URL: https://codereview.chromium.org//22859038

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26500 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-22 01:15:58 +00:00
jacobr@google.com 339b0bdd70 Attempt to land Dartium roll a second time.
BUG=

Review URL: https://codereview.chromium.org//23064024

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26363 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-20 15:54:49 +00:00
jacobr@google.com c6ebe4e4e0 rollback problem blink merge cl
Review URL: https://codereview.chromium.org//23163010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26339 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-20 06:22:24 +00:00
jacobr@google.com 785c8416bc Changes required for Dartium roll
Merge checkpoint. Everything compiles.

BUG=

Review URL: https://codereview.chromium.org//22886009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26335 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-20 01:50:17 +00:00
asiva@google.com 24c3ca0b47 Fix for issue 12489.
R=vsm@google.com

Review URL: https://codereview.chromium.org//23295016

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26327 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-19 20:44:33 +00:00
asiva@google.com f010ffa98d - Add a new toNative which accepts Dart_NativeArguments as a parameter.
Currently it is implemented as two calls to the API to get at the native
  wrapper (will be made one call in another CL).
- Use the new API call Dart_SetWeakHandleReturnValue to return a string
  from the cache directly without having to call Dart_NewHandle(...)

R=vsm@google.com

Review URL: https://codereview.chromium.org//22694004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26148 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-14 20:45:40 +00:00
vsm@google.com cd7a678e83 Use DartExceptionState
R=blois@google.com

Review URL: https://codereview.chromium.org//22605010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25953 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-08 22:56:57 +00:00
asiva@google.com abb3ca866b Do not generate calls to Dart_EnterScope/Dart_ExitScope around native
callbacks as an ApiLocalScope is auto created by the VM when making
external native calls.

R=vsm@google.com

Review URL: https://codereview.chromium.org//22392006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25846 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-06 23:57:50 +00:00
vsm@google.com c5dd3d3ba7 MERGE: 152953-155080
TBR=jacobr@google.com,blois@google.com

Review URL: https://codereview.chromium.org//22357003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25832 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-06 21:17:56 +00:00
asiva@google.com 7376bf6cf2 Alter the native code generator to directly use
Dart_SetBooleanReturnValue
 Dart_SetIntReturnValue
 Dart_SetDoubleReturnValue

instead of 
 Dart_Handle retval = toDart(...); // Calls Dart_Boolean, Dart_NewInteger,
                                   // Dart_Double.
 Dart_SetReturnValue(args, retval);

R=vsm@google.com

Review URL: https://codereview.chromium.org//21156011

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25698 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-01 00:58:22 +00:00
blois@google.com 651836e67b Fixing some SVG collections not working on Dartium.
Issue was that we were generating code calling native methods which were not present for these SVG collections.

BUG=11204
R=vsm@google.com

Review URL: https://codereview.chromium.org//21085008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25682 260f80e4-7a28-3924-810f-c04153c831b5
2013-07-31 20:18:42 +00:00
vsm@google.com 992776552a Fixes for Blink roll.
TBR=jacobr@google.com,asiva@google.com

Review URL: https://codereview.chromium.org//19820007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25395 260f80e4-7a28-3924-810f-c04153c831b5
2013-07-24 04:46:29 +00:00
amouravski@google.com c0a39d0412 Make html metadata follow the spec.
Per https://code.google.com/p/dart/issues/detail?id=11568

R=scheglov@google.com

Review URL: https://codereview.chromium.org//18182010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24638 260f80e4-7a28-3924-810f-c04153c831b5
2013-07-01 18:34:30 +00:00
blois@google.com 9dd81d94a7 Fixing up DOM constructors.
This is a continuation of https://codereview.chromium.org/17063007/

Basically I changed it so factory constructors are only added if the class derives from a native type. Otherwise the native type now extends Interceptor.

BUG=
R=sra@google.com

Review URL: https://codereview.chromium.org//18054021

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24619 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-29 00:14:23 +00:00
blois@google.com 6b44f65407 Revert "Making all DOM types abstract and removing superfluous Dartium constructors."
This reverts commit http://code.google.com/p/dart/source/detail?r=24241.

Compiler error, not sure of best fix.

BUG=

Review URL: https://codereview.chromium.org//17508002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24245 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-20 19:37:47 +00:00
blois@google.com c3547d4e9b Making all DOM types abstract and removing superfluous Dartium constructors.
Adding factory constructors to all classes to suppress missing generative constructor warnings.

Adding a throw to Dartium's base DOM class to prevent construction of native objects.

This also includes the changes necessary to make all DOM types abstract, but I'm running into a dart2js issue which is preventing that.
BUG=
R=vsm@google.com

Review URL: https://codereview.chromium.org//17063007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24241 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-20 17:31:36 +00:00
antonm@google.com a352956d29 Chrome roll 202464->204370.
TBR=vsm@google.com

Review URL: https://codereview.chromium.org//16234006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23743 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-07 14:56:12 +00:00
antonm@google.com 081a2be830 Allow null strings in setters.
V8 generator always allows nulls for Reflect attributes of type
DOMString.  That looks somewhat hairy, but let's just follow the logic
for Dart as well.

R=podivilov@chromium.org
BUG=8189

Review URL: https://codereview.chromium.org//16329002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23541 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-03 13:26:11 +00:00
vsm@google.com b85b97cbe6 Fixes for Blink roll to r151189
TBR=antonm

Review URL: https://codereview.chromium.org//16308002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23511 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-02 18:34:36 +00:00
blois@google.com a1f522165f Modernizing HttpRequest documentation.
Also fixing docs so they get applied to Dartium.

BUG=https://code.google.com/p/dart/issues/detail?id=10547
R=efortuna@google.com

Review URL: https://codereview.chromium.org//15819003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23303 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-28 19:33:06 +00:00
antonm@google.com fd3c7da1ee Verify that correct number of arguments was passed.
R=amouravski@google.com

Review URL: https://codereview.chromium.org//15850004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23296 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-28 17:42:13 +00:00
antonm@google.com 6e51015ab7 Remove now unused attribute.
R=vsm@google.com

Review URL: https://codereview.chromium.org//15732002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23033 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-22 18:12:59 +00:00
antonm@google.com 1d6243bb18 Changes for the roll.
TBR=vsm@google.com

Review URL: https://codereview.chromium.org//15250010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22942 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-21 14:18:00 +00:00
vsm@google.com 8379279dc0 Retry "Changes for webkit roll 148757-149482"
TBR=antonm

Review URL: https://codereview.chromium.org//14948011

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22801 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 16:39:09 +00:00
vsm@google.com 45fc399cf7 Revert "Changes for webkit roll 148757-149482"
TBR=antonm

Review URL: https://codereview.chromium.org//14636013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22769 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 06:06:49 +00:00
vsm@google.com da46c65d3b Changes for webkit roll 148757-149482
Review URL: https://codereview.chromium.org//14954007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22765 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 05:37:13 +00:00
blois@google.com d8eecf70f8 Explicitly implementing some DOM iterable APIs for performance
The move to mixins severely regressed dart2js DOM performance, this patches it some while work continues.
BUG=
R=sra@google.com

Review URL: https://codereview.chromium.org//14619013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22575 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-09 23:31:19 +00:00
blois@google.com 75770524fa Changing metadata lookup to always use interface.id
We had some discrepancies where interface lookup was using interface.doc_js_name but member lookup was using interface.id.

Standardized on interface.id.

Also updated the @DomName annotation to always use the JS interface name, which should help with MDN fallback documentation.

BUG=
R=sra@google.com

Review URL: https://codereview.chromium.org//14651019

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22556 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-09 18:41:07 +00:00
ager@google.com e324ba7ec5 Preserve nullability when writing idl with the ildrenderer. Use nullability to call the toNativeWithNullCheck variant of conversion functions in dartium.
R=antonm@google.com, vsm@google.com
BUG=dartbug.com/3890

Review URL: https://codereview.chromium.org//14761002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22226 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-01 09:01:58 +00:00
blois@google.com 72cf63c068 Refactoring DOM annotations and comment generation, adding DOM API triage list
This pulls the annotation and comment code out of generator.py and into a Metadata class, which is also tracking new APIs from the IDLs.

Right now the API triage list is being updated when new members appear, but is not adding any metadata to the Dart APIs. Of note for the triage list is that there are currently 437 untriaged members- these are all of the APIs which have either been introduced, renamed or moved in the past week.

BUG=
R=sra@google.com

Review URL: https://codereview.chromium.org//14455007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22193 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-30 18:35:30 +00:00
antonm@google.com 3b24778190 Allow null assignments if there is a corresponding marker.
R=podivlov@chromium.org
BUG=10025

Review URL: https://codereview.chromium.org//14190019

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22067 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-26 08:48:27 +00:00
antonm@google.com a33ec28265 Proper support for ForceOptional.
R=ager@google.com, podivilov@chromium.org

Review URL: https://codereview.chromium.org//14373013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22021 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-25 10:35:27 +00:00
antonm@google.com 12d5e65894 Chrome roll.
TBR=ager@google.com, podivilov@chromium.org

Review URL: https://codereview.chromium.org//14211014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21967 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-24 18:02:30 +00:00
ager@google.com 7f79491c06 Move to new dart:typeddata types
Mads: if you land this, please rerun go.sh from tools/dom/scripts to regenerate html_dart2js.dart.  I didn't include it here to make this patchable.

Stephen: I still need to run the perf tests we talked about to sanity check.

Review URL: https://codereview.chromium.org//14367012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21789 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-22 08:22:51 +00:00
antonm@google.com 4520cca2b5 Drop raises annotations support.
R=blois@google.com

Review URL: https://codereview.chromium.org//14150007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21725 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-19 08:59:39 +00:00
antonm@google.com b693f3e1ea Changes for the roll.
TBR=ager@google.com, blois@google.com, podivilov@chromium.org

Review URL: https://codereview.chromium.org//14007012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21627 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-17 16:15:01 +00:00
podivilov@google.com 468fc08f93 Fix the build with WEB_AUDIO disabled.
Make sure web_audio_DartResolver.cpp is generated even if WEB_AUDIO is disabled
because our gyps depend on it.

R=antonm@google.com

Review URL: https://codereview.chromium.org//13493010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21182 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-10 08:01:28 +00:00
blois@google.com 575512855b Fixing SVGColor DartC break
The base class for SVGColor was removed, but we still had an auto-generated constructor trying to call it, which broke dartc.

BUG=

Review URL: https://codereview.chromium.org//13849002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21124 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-08 23:49:16 +00:00
antonm@google.com 55b39086a5 Support nullable attributes and return types in Dartium.
R=vsm@google.com

Review URL: https://codereview.chromium.org//13201004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20660 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-29 15:13:00 +00:00
efortuna@google.com 58b10f811e Reapply Futureification.
BUG=

Review URL: https://codereview.chromium.org//12543014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19590 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-07 00:13:57 +00:00
efortuna@google.com 60a5ed7215 "Reverting 19586"
BUG=

Review URL: https://codereview.chromium.org//12463028

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19587 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-06 22:43:47 +00:00
efortuna@google.com 18f08c3a4c Future-ify All the methods!
(with a few exceptions we've planned).
Also added some tests to test these apis.

BUG=

Review URL: https://codereview.chromium.org//12380046

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19586 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-06 22:32:54 +00:00
efortuna@google.com ce74c20fdb Add supported checks to the SVG library, and library cleanup.
BUG=

Review URL: https://codereview.chromium.org//12082122

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@17994 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-01 19:09:11 +00:00
amouravski@google.com 956d645a0f Can now correctly add documentation to constructors.
Review URL: https://codereview.chromium.org//12087112

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@17954 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-31 23:11:31 +00:00
efortuna@google.com 473bbc0487 "Reverting 17940"
BUG=

Review URL: https://codereview.chromium.org//12095088

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@17941 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-31 19:48:36 +00:00
efortuna@google.com cab5d4cc51 SVG Library cleanups and adding supported tag.
BUG=

Review URL: https://codereview.chromium.org//12038036

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@17940 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-31 19:38:00 +00:00