mirror of
https://github.com/servo/servo.git
synced 2025-08-23 06:15:35 +01:00
Change bindings generation to make Exposed annotation aware of members/partial interfaces
This commit is contained in:
parent
2b84348372
commit
871239a3e3
25 changed files with 151 additions and 78 deletions
|
@ -9,7 +9,7 @@
|
|||
|
||||
[
|
||||
ExceptionClass,
|
||||
Exposed=(Window,Worker),
|
||||
Exposed=(Window,Worker,Worklet,DissimilarOriginWindow),
|
||||
Constructor(optional DOMString message="", optional DOMString name="Error")
|
||||
]
|
||||
interface DOMException {
|
||||
|
|
|
@ -14,7 +14,8 @@
|
|||
// way to enforce security policy.
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#location
|
||||
[Unforgeable, NoInterfaceObject] interface DissimilarOriginLocation {
|
||||
[Exposed=(Window,DissimilarOriginWindow), Unforgeable, NoInterfaceObject]
|
||||
interface DissimilarOriginLocation {
|
||||
[Throws] attribute USVString href;
|
||||
[Throws] void assign(USVString url);
|
||||
[Throws] void replace(USVString url);
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
// way to enforce security policy.
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#window
|
||||
[Global, NoInterfaceObject]
|
||||
[Global, Exposed=(Window,DissimilarOriginWindow), NoInterfaceObject]
|
||||
interface DissimilarOriginWindow : GlobalScope {
|
||||
[Unforgeable] readonly attribute WindowProxy window;
|
||||
[BinaryName="Self_", Replaceable] readonly attribute WindowProxy self;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
* https://dom.spec.whatwg.org/#interface-eventtarget
|
||||
*/
|
||||
|
||||
[Constructor, Exposed=(Window,Worker,Worklet)]
|
||||
[Constructor, Exposed=(Window,Worker,Worklet,DissimilarOriginWindow)]
|
||||
interface EventTarget {
|
||||
void addEventListener(
|
||||
DOMString type,
|
||||
|
|
|
@ -5,6 +5,6 @@
|
|||
// This interface is entirely internal to Servo, and should not be accessible to
|
||||
// web pages.
|
||||
|
||||
[Exposed=(Window,Worker,Worklet),
|
||||
[Exposed=(Window,Worker,Worklet,DissimilarOriginWindow),
|
||||
Inline]
|
||||
interface GlobalScope : EventTarget {};
|
||||
|
|
|
@ -556,6 +556,19 @@ interface TestBinding {
|
|||
|
||||
GlobalScope entryGlobal();
|
||||
GlobalScope incumbentGlobal();
|
||||
|
||||
[Exposed=(Window)]
|
||||
readonly attribute boolean semiExposedBoolFromInterface;
|
||||
};
|
||||
|
||||
[Exposed=(Window)]
|
||||
partial interface TestBinding {
|
||||
readonly attribute boolean boolFromSemiExposedPartialInterface;
|
||||
};
|
||||
|
||||
partial interface TestBinding {
|
||||
[Exposed=(Window)]
|
||||
readonly attribute boolean semiExposedBoolFromPartialInterface;
|
||||
};
|
||||
|
||||
callback SimpleCallback = void(any value);
|
||||
|
|
|
@ -3,5 +3,5 @@
|
|||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#the-windowproxy-exotic-object
|
||||
[NoInterfaceObject]
|
||||
[Exposed=(Window,DissimilarOriginWindow), NoInterfaceObject]
|
||||
interface WindowProxy {};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue