Webview景观 [英] Webview Landscape

查看:63
本文介绍了Webview景观的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试找到一种实现方式,使我的ios Web视图处于横向模式,而我的应用程序的其余部分处于纵向模式.有人知道这是否可能吗?

I'm trying to figure out a way to make it so that my ios webview is in landscape mode while the rest of my app is in portrait. Does anyone know if this is possible?

我有一个视频部分,可以链接到vimeo. vimeo视频播放器在webview中显示,这是我希望在风景中显示的部分.

I have a video section that I link out to vimeo. The vimeo video player is brought up in webview which is the portion I would like in landscape.

推荐答案

您必须以编程方式在shouldAutorotateToInterfaceOrientation中进行此操作 webview.transform=CGAffineTransformMakeRotation(M_PI/2);

you must do it programatically in the shouldAutorotateToInterfaceOrientation webview.transform=CGAffineTransformMakeRotation(M_PI/2);

这篇关于Webview景观的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆