Auto merge of #22917 - ksqsf:master, r=KiChjang

Add optional annotations for initEvent method of Event interface

Added `optional` and default values to parameters `bubbles` and `cancelable` of `initEvent` of `Event`.

I tried to update test results, but there seem to be no differences at all.

I checked similar code where `optional` is used, and there seems to be no special handling in Rust. If that is not the case with this issue, please let me know and I'll commit more follow-ups.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #22883

<!-- Either: -->
- [x] There are tests for these changes OR

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/22917)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2019-02-27 04:05:57 -05:00 committed by GitHub
commit 42ebf46172
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 1 additions and 7 deletions

View file

@ -35,7 +35,7 @@ interface Event {
[Constant]
readonly attribute DOMTimeStamp timeStamp;
void initEvent(DOMString type, boolean bubbles, boolean cancelable);
void initEvent(DOMString type, optional boolean bubbles = false, optional boolean cancelable = false);
};
dictionary EventInit {