AirPlaySupport inherits from MediaControllerSupport, which enables the support object at construction time. This means that the controls will always add a airplay route availability listener, even if they are invisible. They will be disabled eventually, but that's too late, as the listener has already kicked off the airplay route listening machinery.
<rdar://problem/40272213>
Additionally, the AirPlaySupport object should remain disabled when displaying only the "big play button" on iOS, since there's no visible airplay route change button.
Created attachment 340577 [details] Patch
Comment on attachment 340577 [details] Patch Clearing flags on attachment: 340577 Committed r231899: <https://trac.webkit.org/changeset/231899>
All reviewed patches have been landed. Closing bug.
This change appears to have caused the following two LayoutTests to become flaky timeouts on macOS: media/modern-media-controls/scrubber-support/scrubber-support-drag.html media/modern-media-controls/volume-support/volume-support-click.html https://webkit-test-results.webkit.org/dashboards/flakiness_dashboard.html#showAllRuns=true&tests=media%2Fmodern-media-controls%2Fscrubber-support%2Fscrubber-support-drag.html https://webkit-test-results.webkit.org/dashboards/flakiness_dashboard.html#showAllRuns=true&tests=media%2Fmodern-media-controls%2Fvolume-support%2Fvolume-support-click.html
Reverted r231899 for reason: Caused flakiness in two existing modern-media-controls tests. Committed r231923: <https://trac.webkit.org/changeset/231923>
*** Bug 185751 has been marked as a duplicate of this bug. ***
Committed r231950: <https://trac.webkit.org/changeset/231950>