Before, we were returning None, which gets converted to 0.
Derp.
Also fix a flake8 failure introduced by 9f5fbb3066c9.
We'll also need to generate a new decision image. But that will
require someone with TC privileges to be around. That can be done
in a separate commit to unblock this from landing and fixing
consumers of run-task that aren't the decision image.
MozReview-Commit-ID: 6XuoIxjDozF
--HG--
extra : rebase_source : 836f4996cb9be24e19504f73792b159f0ffbdbee
1. It is called from DormantTimerExpired(). The timer is canceled in Shutdown().
2. It is called from NotifyOwnerActivityChanged() which happens before Shutdown().
3. It is called from Play() which happens before Shutdown().
4. It is called from Seek() which happens before Shutdown().
MozReview-Commit-ID: EnKHF61FBXf
--HG--
extra : rebase_source : 04df59b6722c8340e5163a00eb916442799cfcf1
We don't need to check IsShutdown() which is a subset of |mPlayState != PLAY_STATE_PAUSED && !IsEnded()|.
MozReview-Commit-ID: BjYoLOLuPfC
--HG--
extra : rebase_source : 0d04b30a8bf955faed4907f77f0da29e0ccc011d
1. It is called from DurationChanged() which returns early when IsShutdown() is true.
2. It is called from Play() when IsEnded() is true.
MozReview-Commit-ID: Ixy5OMZHxIm
--HG--
extra : rebase_source : 4cd7229084c6af8b7123ee6c85156ef4932308f3
1. It is called from ChangeState() when IsEnded() is true.
2. It is called from OnMetadataUpdate(). The callback is disconnected in Shutdown().
MozReview-Commit-ID: 8m4jtcl91hT
--HG--
extra : rebase_source : 0988128ec6d05f07ab7b072cc70a9c2970c829c5
1. Pause() is called from HTMLMediaElement and happens before Shutdown().
2. Pause() is called from SetPlaybackRate() which is called from HTMLMediaElement.
MozReview-Commit-ID: DDr7Bg8jkF2
--HG--
extra : rebase_source : 8b8a4fdc914d0bce7572d9a1ccb0f530bdba062c
FireTimeUpdate() is only called from UpdateLogicalPositionInternal() which returns early when IsShutdown() is true.
MozReview-Commit-ID: 4GZwrI85aXj
--HG--
extra : rebase_source : 9d7cbd571fd794369c833723ea5fc50a26380e51
1. ConstructMediaTracks() is called from ChangeState() when |mPlayState == PLAY_STATE_PLAYING|.
2. ConstructMediaTracks() is called from MetadataLoaded() which asserts |!IsShutdown()|.
MozReview-Commit-ID: 6OaPYcCOCii
--HG--
extra : rebase_source : 9db9e841fe8a0d797a39cd527abf4f4e95b67131
In nsGlobalWindow, we have a static counter for how many popups we've seen
recently. We increment it and decrement it when popups open and close - although
the decrement only occurs once the DocShell is detached, which happens asynchronously.
The test uses a utility that returns Promises for window.open and window.close,
but it uses dom-window-destroyed for resolving close, which happens _before_ the
counter is decremented. The dom-window-destroyed observer queues a runnable which
resolves the Promise.
This means that the test is attempting to open windows before the windows from a
previous test have finished detaching their DocShells (and decrementing the counter),
which means that the attempts to open the window hit the popup limit, which blocks
the popups.
This test switches us to waiting for outer-window-destroyed instead, which gives us
a greater certainty that the decrement has occurred.
MozReview-Commit-ID: 3a7QzxelP0a
There were two issues:
1) The keys/entries/values/forEach properties were being added no matater what
the value of the 'unforgeable' boolean was. So we ended up spitting out
unforgeable versions of those, and this confused some Xray cases.
2) The number of args listed for forEach was wrong, which hit assertions in the
JS engine because the same self-hosted function was being instantiated with
different numbers of args from different places.