Implement AudioParam.cancelScheduledValues

RESOLVED FIXED in mozilla19

Status

()

defect
RESOLVED FIXED
7 years ago
6 years ago

People

(Reporter: Ehsan, Assigned: Ehsan)

Tracking

Trunk
mozilla19
x86
macOS
Points:
---
Dependency tree / graph
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

No description provided.
Posted patch Patch (v1)Splinter Review
Assignee: nobody → ehsan
Status: NEW → ASSIGNED
Attachment #676849 - Flags: review?(bzbarsky)
Comment on attachment 676849 [details] [diff] [review]
Patch (v1)

>+        mEvents.RemoveElementsAt(i, mEvents.Length() - i);

  mEvents.TruncateLength(i);

r=me
Attachment #676849 - Flags: review?(bzbarsky) → review+
One other thought.... would it make sense to binary search instead of linear search here?
(In reply to comment #4)
> One other thought.... would it make sense to binary search instead of linear
> search here?

Maybe.  I don't yet know how many events will be typically set on an AudioParam, so depending on the real world use case that may not be worth it.  I have a comment in AudioEventTimeline.h which says how mEvents can be optimized in the future if we need to.
https://hg.mozilla.org/mozilla-central/rev/5fc85295afde
Status: ASSIGNED → RESOLVED
Last Resolved: 7 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla19
Mass moving Web Audio bugs to the Web Audio component.  Filter on duckityduck.
Component: Video/Audio → Web Audio
You need to log in before you can comment on or make changes to this bug.