Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added ImageBitmap interface #210

Merged
merged 2 commits into from
Mar 7, 2017
Merged

Conversation

nkemnitz
Copy link
Contributor

@nkemnitz nkemnitz commented Mar 2, 2017

Fixes ImageBitmap interface missing #14402

Adds interfaces ImageBitmap, ImageBitmapOptions and the associated typedefs to Window and Worker scope. See WHATWG HTML Living Standard

Wasn't sure about the "flavor" tag. Worker seems to be the one I need here. but is there a description of All, Web, DOM and maybe others?

@msftclas
Copy link

msftclas commented Mar 2, 2017

@nkemnitz,
Thanks for having already signed the Contribution License Agreement. Your agreement was validated by Microsoft. We will now review your pull request.
Thanks,
Microsoft Pull Request Bot

@@ -89,6 +89,120 @@
]
},
{
"kind": "typedef",
"flavor": "Worker",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should be "Web", DOM interfaces are not available in Web Workers.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We will need two entries for createImageBitMap, or at least two definitions for ImageBitmapSource, one for WebWorkers that does not have HTMLImageElement, SVGElement, HTMLVideoElement, or HTMLCanvasElement

"kind": "typedef",
"flavor": "Worker",
"name": "ImageBitmapSource",
"type": "CanvasImageSource | Blob | ImageData"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

consolodate all the types in one type def. we try to avoid polluting the global namespace.

type ImageBitmapSource = HTMLImageElement | SVGImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap; | Blob | ImageData;

@nkemnitz
Copy link
Contributor Author

nkemnitz commented Mar 2, 2017

Thanks for the explanation!
I removed the typedefs for both, ImageBitmap and ImageBitmapOptions, as well as the unavailable HTMLElements in the Web Worker createImageBitmap call.

The failing Travis CI build seems not related to the code changes.

@nkemnitz nkemnitz closed this Mar 2, 2017
@nkemnitz nkemnitz reopened this Mar 2, 2017
@msftclas
Copy link

msftclas commented Mar 2, 2017

@nkemnitz,
Thanks for having already signed the Contribution License Agreement. Your agreement was validated by Microsoft. We will now review your pull request.
Thanks,
Microsoft Pull Request Bot

@nkemnitz
Copy link
Contributor Author

nkemnitz commented Mar 2, 2017

Closed/Reopened PR to trigger the travis-ci build (Failed yesterday due to "Service temporarily unavailable" error)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants