是否可以更改iOS 8 Action Extension的视图大小? [英] Is it possible to change the view size of iOS 8 Action Extension?

查看:109
本文介绍了是否可以更改iOS 8 Action Extension的视图大小?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在为iOS 8开发一个动作扩展程序。我希望视图是全屏的,它在iPhone上,但不在iPad上,在iPad上,我的扩展名在中间的小视图中显示。是否有可能使它在iPad上全屏显示?

I'm developing an action extension for iOS 8 at the moment. I want the view to be full screen, and it is on the iPhones, but not on the iPad, on the iPad my extension is presented in a small view in the middle. Is it possible to make it so that it's full screen on the iPad too?

推荐答案

经过一番搜索我发现我需要做的就是把

After a bit of searching around I found all I needed to do was put

[self setPreferredContentSize:CGSizeMake(760.0f, 1024)];

在viewDidLoad中

in viewDidLoad

这篇关于是否可以更改iOS 8 Action Extension的视图大小?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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