Android 只能将 View 旋转 90 度
我有两种看法。我想将一个视图旋转 90 度,可以吗?我的视图是 Admob 视图。我的 admobview 现在显示在左侧屏幕上。图片:
我想将该视图旋转 90 度,到达视图的底部。是否可以? 我有一个代码,但不起作用,当 admob 刷新时,视图状态会更改为原始状态。:(
编辑:我处于纵向模式,我不想将其更改为风景,谢谢。
I have twoo views. I want to rotate one view by 90 degrees, is it possible? My view is an Admob View. My admobview now shows on the screens left. Picture:
I d like to rotate that view by 90 degrees, to my view's bottom. Is it possible?
I have a code, but is not working, and when the admob is refreshing than the views state change to the original state.:(
Edit: I am in portrait mode and i dont want to change it to landscape, thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可能不想更改为横向,但这并不能改变它是正确答案的事实。 ;)
即使您的应用程序要求全屏模式,蜂窝设备也会使用当前方向来确定屏幕底部系统栏的方向。这也用于定向最近任务切换器的屏幕截图,并且将来可能会继续用于更多类似的事情。
您可以编写一个简单的自定义父视图,它将旋转测量、布局和绘图来处理您当前的问题,但正确的答案仍然是在横向模式下运行您的应用程序。如果您继续沿着这条路走下去,您的应用程序将会以多种方式被破坏,您将无法破解这些方式。
You may not want to change to landscape, but that doesn't change the fact that it's the right answer. ;)
Honeycomb devices use the current orientation to orient the system bar at the bottom of the screen even when your app asks for full-screen mode. This is also used to orient screenshots for the recent task switcher, and it will probably continue to be used for more things like this in the future.
You can write a trivial custom parent view that will rotate the measurement, layout, and drawing to handle your current problem, but the right answer is still to run your app in landscape mode. Your app will be broken in a number of ways that you will not be able to hack around if you continue down this path.