gpt4 book ai didi

android - 没有足够的空间来展示广告!想要 : <480, 75>,有 : <454, 90>

转载 作者:行者123 更新时间:2023-11-29 14:50:01 25 4
gpt4 key购买 nike

我正在尝试在我的 Android 应用程序中显示 adMobs。但是在 logCat 中它给了我以下内容

 Not enough space to show ad! Wants: <480, 75>, Has: <454, 90>

这是我的布局

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:ads="http://schemas.android.com/apk/lib/com.google.ads"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >

<com.google.ads.AdView
android:id="@+id/adView"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
ads:adSize="BANNER"
ads:adUnitId="@string/adUnitId"
ads:loadAdOnCreate="true"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
ads:testDevices="TEST_EMULATOR, TEST_DEVICE_ID" />

<ListView
android:id="@+id/tipList"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_below="@+id/buttons"
android:divider="#C0C0C0"
android:dividerHeight="2px"
android:scaleType="fitXY"
android:choiceMode="singleChoice"
android:layout_marginLeft="12dp"
android:listSelector="@drawable/list_selector" />

</LinearLayout>

如何解决?提前致谢。

最佳答案

设置父项:

android:paddingLeft="0dp"

android:paddingRight="0dp"

我就是这样解决的。

关于android - 没有足够的空间来展示广告!想要 : <480, 75>,有 : <454, 90>,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21455060/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com