从 UIWebView 启动 YouTube,它始终处于横向状态
我按照 此示例来自 YouTube API 博客,其 HTML 类似于:
<object width='320' height='260'>
<param name='movie' value='http://www.youtube.com/v/{0}&f=gdata_videos'></param>
<param name='wmode' value='transparent'></param>
<embed src='http://www.youtube.com/v/{0}&f=gdata_videos' type='application/x-shockwave-flash' wmode='transparent' width='320' height='260'></embed>
</object>
当我单击 UIWebView
中的缩略图和“播放”按钮时,YouTube 应用以横向模式启动。 UIWebView 本身是纵向的,就像大多数应用程序一样,所以这有点令人讨厌,特别是如果特定视频也是纵向拍摄的。
有什么方法可以控制启动的 YouTube 应用程序的方向吗?我尝试交换 HTML 中的宽度和高度,但这虽然会影响缩略图,但不会影响 YouTube 应用。
I'm launching YouTube from an embed in a UIWebView
as per this example from the YouTube API blog, with HTML something like:
<object width='320' height='260'>
<param name='movie' value='http://www.youtube.com/v/{0}&f=gdata_videos'></param>
<param name='wmode' value='transparent'></param>
<embed src='http://www.youtube.com/v/{0}&f=gdata_videos' type='application/x-shockwave-flash' wmode='transparent' width='320' height='260'></embed>
</object>
When I click the thumbnail and "play" button in the UIWebView
, the YouTube app launches in landscape mode. The UIWebView
itself is in portrait orientation, as is most of the app, so this is kind of obnoxious, especially if the particular video is also shot in portrait.
Is there any way to control the orientation of the launched YouTube app? I tried swapping the width and height in the HTML, but while that affects the thumbnail, it doesn't affect the YouTube app.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论