Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Purpose of mediaPlaybackAllowsAirPlay property on UIWebView

Tags:

ios

airplay

The UIWebView Class Reference describes mediaPlaybackAllowsAirPlay as follows:

A Boolean value that determines whether Air Play is allowed from this view.

When the mediaPlaybackAllowsAirPlay is set to YES: If on my iPad I load a YouTube or Vimeo video to a UIWebView with this set to it's default value of YES and play the video while mirroring to an AirPlay device, the video signal is sent to the AirPlay device and takes over the AirPlay device screen and "TV Connected / This video is playing on the TV" is displayed in the UIWebView on the AirPlay. This is the behavior I would expect.

When the mediaPlaybackAllowsAirPlay is set to NO: I get exactly the same behavior as above. What I expected is that if the UIWebView mediaPlaybackAllowsAirPlay was set to NO, that instead of sending the video signal to the AirPlay device, even if the iPad is mirroring, the video would simply play inside the UIWebView on the iPad.

Has anyone used this property to create two different functional behaviors and what were they?

As far as I can tell, this property has no impact on the playing of AirPlay media.

like image 934
Rob Reuss Avatar asked Mar 21 '12 19:03

Rob Reuss


1 Answers

It appears that the mirroring mode is taking precedence over the mediaPlaybackAllowsAirPlay flag.

If I'm interpreting the documentation correctly, mediaPlaybackAllowsAirPlay only allows the user to send the data to a particular airplay compatible device. If it is disabled, the airplay selector simply doesn't show up.

If this is a bug to you, please head over to http://bugreporter.apple.com and let Apple know.

like image 80
Brandon A Avatar answered Oct 11 '22 14:10

Brandon A