Boris Zbarsky
8e1e530404
Bug 779048 part 8. Handling of arguments for callbacks. r=peterv
...
Note that we're now using the array object as the "obj" when wrapping
sequence members, because we don't have an 'obj' around in our
code... and every single existing sequence-of-interfaces consumer
relied on there being an 'obj' floating about.
Also note that I needed to rearrange the various wrapping helpers so
that we can wrap things that are hanging out in const smartpointers or
in const OwningNonNull or in plain object references.
2012-11-09 07:43:58 -08:00
Boris Zbarsky
b89fa1202f
Bug 779048 part 7. Make native-to-JS conversion support doing something other than "return false" on JS exceptions. r=peterv
2012-11-09 07:43:58 -08:00
Boris Zbarsky
0e77c9690d
Bug 779048 part 6. Handling of return values for callbacks. r=peterv
2012-11-09 07:43:58 -08:00
Boris Zbarsky
cd39216d1f
Bug 779048 part 5. Make js-to-native conversion support doing something other than "return false" on JS exceptions. r=peterv
2012-11-09 07:43:58 -08:00
Boris Zbarsky
a2a68bed98
Bug 779048 part 4. Implement basic codegen for callbacks, without handling of arguments or return values yet. r=peterv
2012-11-09 07:43:57 -08:00
Boris Zbarsky
925b496c42
Bug 779048 part 3. Refactor the code we use for generating example declarations a bit so we can reuse it for callbacks. r=peterv
2012-11-09 07:43:57 -08:00
Boris Zbarsky
a850d34469
Bug 779048 part 2. Rearrange how we do our includes and forward-declares to actually work with callbacks and dictionaries sanely. r=peterv
2012-11-09 07:43:57 -08:00
Boris Zbarsky
e38decd8a4
Bug 808991. Named getters should get called for indexed properties on objects that don't support indexed properties. r=peterv
2012-11-08 23:48:42 -08:00
Robert O'Callahan
bac0aef69c
Bug 792675. Part 1: Make the URL interface use WebIDL. r=bz
2012-09-25 15:24:43 +12:00
Robert O'Callahan
069a612526
Bug 792675. Part 0.6: Handle empty dictionary types in WebIDL bindings. r=bz
2012-11-07 17:56:55 -05:00
Robert O'Callahan
6ddc06a037
Bug 792765. Part 0.5: Fix WebIDL codegen to avoid emitting QueryInterface when there is no interface prototype object. r=bz
2012-09-25 15:24:43 +12:00
Boris Zbarsky
ec7cd32f9b
Bug 804738 part 2. Fix codegen for indexed operations to be consistent about the naming of the index argument. r=peterv
2012-11-06 08:01:49 -08:00
Boris Zbarsky
961c289911
Bug 804738 part 1. Fix codegen for named operations to be consistent about the naming of the string argument. r=peterv
2012-11-06 08:00:57 -08:00
Boris Zbarsky
27ae9926f5
Bug 804635. Make codegen deal with Document not being an external interface but not available in workers even though XMLHttpRequest (which can return or accept Document) is available there. r=peterv
2012-11-05 11:58:04 -05:00
Boris Zbarsky
24f00dd561
Bug 803519. Require indexed/named getters if we have creators/deleters/setters. r=peterv
2012-11-05 11:58:03 -05:00
Boris Zbarsky
4a2ba45478
Bug 772869. Make getOwnPropertyNames work correctly for WebIDL proxy bindings. r=peterv,ms2ger
2012-11-05 11:58:03 -05:00
Boris Zbarsky
1c62677f2e
Bug 803306. Calling a named creator should not define an expando. r=peterv
2012-11-05 11:58:03 -05:00
Boris Zbarsky
7d25f8f24f
Bug 788225. Implement WebIDL deleters. r=peterv
2012-11-05 11:58:02 -05:00
Boris Zbarsky
6d8bbce3fc
Bug 749866 part 4. Generate slightly better code when we know we're null or undefined. r=khuey
2012-11-05 11:58:02 -05:00
Boris Zbarsky
581a4b971c
Bug 749866 part 3. Rejigger overload resolution a bit more so we can tell argument conversion that we know the argument is null or undefined. r=khuey
2012-11-05 11:58:02 -05:00
Boris Zbarsky
b762a55553
Bug 749866 part 2. Simplify the code generated by overload resolution a bit when we have sequences or dates at our distinguishing index. r=khuey
2012-11-05 11:58:02 -05:00
Boris Zbarsky
4e61c01320
Bug 749866 part 1. Add support for failureCode for sequence unwrapping. r=khuey
2012-11-05 11:58:02 -05:00
William Chen
d1af75e2b2
Bug 807034 - Fix WebIDL codegen for static readonly attributes. r=bz
2012-10-30 11:38:58 -07:00
Vendelin Ruzicka
f5b244c1ab
Bug 806184 - Can't use 'delete' method in WebIDL. r=bz
2012-10-31 13:36:20 +01:00
Peter Van der Beken
29377d8150
Fix for bug 763643 (Implement static operations and attributes for WebIDL). r=bz.
2012-10-19 09:34:28 +02:00
Peter Van der Beken
74736c6026
Fix for bug 778152 (Content window does not have an XMLHttpRequest property when accessed via an Xray wrapper in a subscript). r=bz.
...
Switch from using the interface objects from the Xrays compartment to wrapping
interface objects and interface prototype objects in Xrays. Make dom binding
Xrays deal with both instance objects and interface and interface prototype
objects.
2012-10-09 20:50:27 +02:00
Peter Van der Beken
2603add13a
Fix for bug 785277 (Implement PutForwards in the new DOM bindings). r=bz.
2012-08-13 14:20:49 +02:00
Peter Van der Beken
b2aa62b694
Fix for bug 778152 (Content window does not have an XMLHttpRequest property when accessed via an Xray wrapper in a subscript) - rename ProtoOrIfaceArray. r=bz.
2012-10-09 20:50:27 +02:00
Bobby Holley
60fc9cb7db
Bug 797821 - Address Ms2ger's review comments. r=me
2012-10-25 17:01:09 +02:00
Bobby Holley
491fc4b110
Bug 797821 - Replace usage of XPCWrappedNativeScope::FindInJSObjectScope(ccx, obj) with GetObjectScope(obj). r=mrbkap
2012-10-25 17:01:08 +02:00
Boris Zbarsky
9dcdb067ae
Bug 804725. Use the right type name for interface arguments for binding example codegen. r=jst
2012-10-24 16:10:49 -04:00
Boris Zbarsky
c31bc8e951
Bug 793267. Add support for [Unforgeable] in WebIDL. r=peterv
...
Unforgeable attributes are defined directly on the object, not on the
prototype. So we keep them in a separate spec array and define them
during object creation as needed.
This means that we have to pass that separate spec array to the Xray
helpers, unfortunately, which somewhat complicates those.
2012-10-24 16:10:49 -04:00
Boris Zbarsky
be267542fa
Bug 798187 even more followup. Disable broken WebGL test, and update to Peter's review comments. r=peterv
2012-10-22 15:14:30 -04:00
Boris Zbarsky
ec8fbbcbed
Bug 798187 followup. Actually return our newly-created object from dictionary ToObject. r=peterv
2012-10-22 14:35:08 -04:00
Boris Zbarsky
0173fe62ec
Bug 798187 part 1. Add support for dictionary return values. r=peterv
2012-10-22 13:08:52 -04:00
Boris Zbarsky
8359177e11
Bug 798151. Support stringifier operations (but not yet attributes!) on non-proxy bindings, and fix Object.prototype.toString for proxy bindings. r=peterv
2012-10-22 13:08:52 -04:00
Boris Zbarsky
b1d20eedf6
Bug 801712 part 3. Make object return values faster by only doing the JS_WrapValue if needed. r=peterv
2012-10-22 13:08:52 -04:00
Boris Zbarsky
0aa2b783ae
Bug 802636. Add a test that makes sure that codegen and example generation agree with each other. r=jst
2012-10-17 21:17:16 -04:00
Boris Zbarsky
fb766c1528
Bug 796983 part 2. Add a way to generate an example class declaration for a given WebIDL interface. r=jst
...
We mark constructors as static in the parser because they are. This
allows us to just use the isStatic() for the IDLMember to mark our
declarations static.
To generate an example interface implementation, just "make
interfacename-example" in $objdir/dom/bindings. This will place files
called interfacename-example.h and interfacename-example.cpp in that
directory. For example, "make XMLHttpRequest-example" will get you
$objdir/dom/bindings/XMLHttpRequest-example.h and
$objdir/dom/bindings/XMLHttpRequest-example.cpp.
Attribute getters currently default to const methods, while setters
and operations default to non-const methods.
2012-10-17 17:01:55 -04:00
Boris Zbarsky
9942688c9d
Bug 796983 part 1. Switch nullable primitives to using a const Nullable. r=jst
2012-10-17 17:01:55 -04:00
Ehsan Akhgari
c5ad528a77
Merge mozilla-central into mozilla-inbound
2012-10-16 20:43:47 -04:00
Olli Pettay
b34aef8a32
Bug 797806 - Helper method to handle stringified JSON in C++, part2, r=khuey
2012-10-16 18:37:44 +03:00
Olli Pettay
2f72f31a9d
Bug 797806 - Helper method to handle stringified JSON in C++, r=khuey
2012-10-16 17:52:10 +03:00
Peter Van der Beken
bd9ee3a1da
Fix for bug 798264 (Split property tables). r=bz.
2012-10-09 20:50:05 +02:00
Peter Van der Beken
f8c638299a
Fix for bug 799465 (Add complete support for non-nsISupports objects in new DOM bindings) - fix CC traversal and wrapper preservation. r=bz.
2012-09-26 20:12:15 +02:00
Trevor Saunders
1c337c0474
Bug 742191 - Part d: Throw TypeErrors for Paris binding exceptions; r=bz
2012-10-16 14:06:10 -04:00
Boris Zbarsky
94e2400252
Bug 792890. Fix JS-wrapping of callback interfaces to just return the underlying JS object. r=peterv
...
There are several changes here:
1) When wrapping a callback interface object for JS, just extract the
underlying JSObject from inside it and hand that object out.
2) Flag callback interface descriptors as "not concrete" (only matters
for cases when they have constants on the interface object) and not
wrappercached (will catch bugs if someone tries to treat them as a
Gecko object).
3) Fix a preexisting bug in sequence wrapping where we'd try to
JS_DefineElement twice if we were wrapping a null value for a
sequence of nullable interface objects.
2012-10-10 15:57:57 -04:00
Boris Zbarsky
a265c27af7
Bug 792137. [TreatNonCallableAsNull] lives on the callback type now. r=peterv
2012-10-10 15:53:02 -04:00
Bobby Holley
351440d25e
Bug 761695 - Implement expando traps for ProxyXrayTraits DOMXrayTraits. r=peterv
...
For new DOM proxies, we could probably use the Xray expando machinery for the
regular expando object as well, and free up one of the reserved slots. That's
more than I want to bite off for the moment, though.
I also decided not to block on bug 760095 and just kick the problem of globals
with new binding down the road a little bit.
2012-10-05 18:59:23 +02:00
Peter Van der Beken
8eb9b454dc
Fix for bug 791774 (Hook DOM lists up to the new DOM bindings). r=bz.
2012-06-13 17:18:30 +02:00