在另一个在运行时的一个布局? [英] One layout over another at run time?

查看:70
本文介绍了在另一个在运行时的一个布局?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的游戏应用程序有许多复杂的图形元素,我很担心,在屏幕上不断有一个横幅广告会减损游戏太多。我的计划是,用户将能够起到在使用全屏幕没有任何广告的游戏中每个电平,但是每个水平完成后的广告将在滑动,在屏幕的顶部部分的顶部。 presumably这意味着我必须以某种方式创建布局编程方式将出现在现有的屏幕布局的顶部。可以这样做?如果是的话怎么样?

My game app has many complex graphical elements and I am worried that having a banner ad continuously on screen will detract too much from the game. My plan is that the user will be able to play each "level" in the game using the full screen without any ads, but upon completion of each level an ad will slide in, on top of the top part of the screen. Presumably this means I have to somehow create a layout programatically that will appear on top of the existing screen layout. Can this be done? If so how?

推荐答案

这是可以做到。
据我所知,你只需要创建一个布局,Android的是:=的backgroundColor透明的。
否则,你可以做到这一点,所以你每个级别上完成开始了新的活动?

It can be done. Afaik you simply have to create a layout which is android:backgroundcolor="transparent". Else you could do it so you started a new activity on each level completion?

这篇关于在另一个在运行时的一个布局?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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