| OLD | NEW |
| 1 APIs | 1 APIs |
| 2 ==== | 2 ==== |
| 3 | 3 |
| 4 The Sky core API | 4 The Sky core API |
| 5 ---------------- | 5 ---------------- |
| 6 | 6 |
| 7 ```javascript | 7 ```javascript |
| 8 module 'sky:core' { | 8 module 'sky:core' { |
| 9 | 9 |
| 10 // EVENTS | 10 // EVENTS |
| (...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 288 // otherwise, it proceeds as follows: | 288 // otherwise, it proceeds as follows: |
| 289 // 0. let prototype be the prototype passed in (defaulting to Element) | 289 // 0. let prototype be the prototype passed in (defaulting to Element) |
| 290 // 1. let constructor be prototype.constructor | 290 // 1. let constructor be prototype.constructor |
| 291 // 2. create a new Function that: | 291 // 2. create a new Function that: |
| 292 // 0. throws if not called as a constructor | 292 // 0. throws if not called as a constructor |
| 293 // 1. initialises the shadow tree is shadow on the options is true | 293 // 1. initialises the shadow tree is shadow on the options is true |
| 294 // 2. calls constructor, if it's not null, with the module as the argum
ent | 294 // 2. calls constructor, if it's not null, with the module as the argum
ent |
| 295 // 3. let that new Function's prototype be the aforementioned prototype | 295 // 3. let that new Function's prototype be the aforementioned prototype |
| 296 // 4. let that new Function have tagName and shadow properties set to | 296 // 4. let that new Function have tagName and shadow properties set to |
| 297 // the values passed in | 297 // the values passed in |
| 298 // 5. register the new element |
| 298 | 299 |
| 299 ScriptElement? currentScript; // O(1) // returns the <script> element curren
tly being executed if any, and if it's in this module; else null | 300 ScriptElement? currentScript; // O(1) // returns the <script> element curren
tly being executed if any, and if it's in this module; else null |
| 300 } | 301 } |
| 301 | 302 |
| 302 class Module : AbstractModule { | 303 class Module : AbstractModule { |
| 303 constructor (Application application, Document document, String url); // O(1
) | 304 constructor (Application application, Document document, String url); // O(1
) |
| 304 readonly attribute Application application; // O(1) | 305 readonly attribute Application application; // O(1) |
| 305 | 306 |
| 306 attribute any exports; // O(1) // defaults to the module's document | 307 attribute any exports; // O(1) // defaults to the module's document |
| 307 } | 308 } |
| (...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 486 the core mojo fabric JS API sky:mojo:fabric:core | 487 the core mojo fabric JS API sky:mojo:fabric:core |
| 487 the asyncWait/cancelWait mojo fabric JS API (interface to IPC thread) sky:moj
o:fabric:ipc | 488 the asyncWait/cancelWait mojo fabric JS API (interface to IPC thread) sky:moj
o:fabric:ipc |
| 488 the mojom for the shell, proxying through C++ so that the shell pipe isn't exp
osed sky:mojo:shell | 489 the mojom for the shell, proxying through C++ so that the shell pipe isn't exp
osed sky:mojo:shell |
| 489 the sky API sky:core | 490 the sky API sky:core |
| 490 the sky debug symbols for private APIs sky:debug | 491 the sky debug symbols for private APIs sky:debug |
| 491 ``` | 492 ``` |
| 492 | 493 |
| 493 TODO(ianh): determine if we want to separate the "this" from the | 494 TODO(ianh): determine if we want to separate the "this" from the |
| 494 Document, especially for Modules, so that exposing a module's element | 495 Document, especially for Modules, so that exposing a module's element |
| 495 doesn't expose the module's exports attribute. | 496 doesn't expose the module's exports attribute. |
| OLD | NEW |