pda/zhuike/.svn/pristine/c5/c595ed20fe5c2bead6fd5659436...

60 lines
3.7 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/white"
>
<!-- 广点通开屏广告支持“半屏/全屏”展示开发者可以把Logo区域放在屏幕底部然后在Logo上方提供一个容器来放置半开屏广告请注意此容器高度不得小于400dp -->
<!-- 1.Logo区域展示半开屏广告时使用如果想展示全开屏广告可以不需要这个Logo区域 -->
<!-- 注意如需要这个Logo区域建议开发者使用自己的Logo资源而不是联盟的Logo资源@drawable/gdt_splash_logo资源规格可参照@drawable/gdt_splash_logo -->
<TextView android:id="@+id/textTile"
android:layout_gravity="center"
android:gravity="center"
android:layout_width="wrap_content"
android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true"
android:layout_height="50dp"
android:textSize="20sp"
android:textStyle="bold"
android:text="" />
<!-- 2.开屏广告容器区域:-->
<!-- 注意该区域高度不得小于400dp。在本示例中没有写死splash_container的高度值是因为第1部分的app_logo区域是一个高度很小的图片。 -->
<FrameLayout
android:id="@+id/splash_container"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@id/textTile"/>
<!-- 3.自定义跳过按钮区域:开发者可以根据需要自己实现不同样式的跳过按钮 -->
<!-- 注意1根据广告法规定跳过按钮必须在屏幕当中出现。因此广告展示的时候必须让将SkipView显示出来即visible否则将SDK将不展示广告返回错误码608。。 -->
<!-- 注意2SDK除了会检查跳过按钮的可见性还将检测它的尺寸其尺寸不得小于3dp*3dp否则将SDK将不展示广告返回错误码608。 -->
<TextView
android:id="@+id/skip_view"
android:layout_width="96dp"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_alignParentTop="true"
android:layout_margin="16dp"
android:layout_marginTop="20dp"
android:background="@drawable/background_circle"
android:gravity="center"
android:text="@string/click_to_skip"
android:textColor="@android:color/white"
android:textSize="14sp"/>
<!-- 本示例省略了自定义的倒计时和跳过按钮放在一起实现了。开发者也可以实现自己的倒计时View方法是在onADTick回调中获得广告剩余的展示时间并自由决定倒计时View的样式SDK对倒计时的View没有要求。 -->
<!-- 4.预设开屏图片区域: -->
<!-- 开发者可以把自家App设计开屏图片摆放在这里本示例中放置了一张静态图片。然后在onADPresent回调中再把这个图片隐藏起来。 !-->
<!-- 注意1直接将此图盖在广告容器的上面即可始终不要将广告容器splash_container的设为invisible否则将不会展示广告无法计费返回错误码600。-->
<!-- 注意2建议开发者使用自己的开屏图片资源而不是联盟的@drawable/splash_holder资源规格可参照@drawable/splash_holder -->
<TextView
android:id="@+id/splash_holder"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@id/textTile"
android:background="@color/black"/>
</RelativeLayout>