IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Android Discussion :

Manifest.xml & Google AdActivity


Sujet :

Android

Vue hybride

Message précédent Message précédent   Message suivant Message suivant
  1. #1
    Membre éclairé
    Homme Profil pro
    Inscrit en
    Mai 2012
    Messages
    535
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Mai 2012
    Messages : 535
    Par défaut Manifest.xml & Google AdActivity
    Hello les experts... encore une fois!

    J'essaye d'inclure un bandeau de pub à mon appli de test.
    J'ai récupéré le SDK chez google, ainsi que des exemples, et pourtant:

    manifest
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    <manifest xmlns:android="http://schemas.android.com/apk/res/android"
        package="bidule.test"
        android:versionCode="1"
        android:versionName="1.0" >
    
        <!-- 11 = 3.0 (api 11)  & 16 = 4.1 (api 16) -->
        <uses-sdk
            android:minSdkVersion="11"
            android:targetSdkVersion="16" />
    
        <application
            android:icon="@drawable/ic_launcher"
            android:label="@string/app_name"
            android:theme="@style/AppTheme" >
            <uses-library android:name="com.google.android.maps" />
    
            <!-- activité PRINCIPALE dans le LAUNCHER -->
            <activity
                android:name=".TestActivity"
                android:label="@string/title_activity" >
                <intent-filter>
                    <action android:name="android.intent.action.MAIN" />
                    <category android:name="android.intent.category.LAUNCHER" />
                </intent-filter>
            </activity>
    
            <activity
                android:name="com.google.ads.AdActivity" 
                android:configChanges="keyboard|keyboardHidden|orientation"/>
    
    </application>
    
        <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
        <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
        <uses-permission android:name="android.permission.INTERNET" />
        <uses-permission android:name="android.permission.LOCATION" />
        <uses-permission android:name="android.permission.ACCESS_GPS" />    
        <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/> 
    </manifest>
    oncreate
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
     
     public void onCreate(Bundle savedInstanceState) 
        {
           	       super.onCreate(savedInstanceState);
      	       setContentView(R.layout.main);
     
    		//>>>
    		TableLayout layout = (TableLayout)findViewById(R.id.tableLayout);
    		AdView adView = new AdView(this, AdSize.BANNER, MY_AD_UNIT_ID);
    		layout.addView(adView);
    	    AdRequest request = new AdRequest();
    	    request.setTesting(true); 
    	    adView.loadAd(request);     
    }

    logcat
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    10-04 07:55:24.388: E/Ads(712): The android:configChanges value of the com.google.ads.AdActivity must include screenLayout.
    10-04 07:55:24.388: E/Ads(712): The android:configChanges value of the com.google.ads.AdActivity must include uiMode.
    10-04 07:55:24.388: E/Ads(712): The android:configChanges value of the com.google.ads.AdActivity must include screenSize.
    10-04 07:55:24.388: E/Ads(712): The android:configChanges value of the com.google.ads.AdActivity must include smallestScreenSize.
    10-04 07:55:24.388: E/Ads(712): You must have AdActivity declared in AndroidManifest.xml with configChanges.
    Bref, bien que la référence à adActivity soit bien renseignée dans le manifeste, il semble ne pas la voir.....

    Une idée peut être.
    Merci.



    EDIT: GoogleAdMobAdsSdk-6.1.0

  2. #2
    Membre éclairé
    Homme Profil pro
    Inscrit en
    Mai 2012
    Messages
    535
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Mai 2012
    Messages : 535
    Par défaut
    Bon, je ne pensais pas du tout que c'était aussi con que ça, d'où le post, MAIS visiblement un simple

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>
    pour qu'il soit content!

    Par contre, il y a quand même un "truc": affichage
    -> émulateur 4.1: OUI
    -> galaxy tab 10.1: NON

  3. #3
    Membre émérite
    Profil pro
    Inscrit en
    Janvier 2011
    Messages
    757
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Janvier 2011
    Messages : 757
    Par défaut
    Alors vérifie les Logs des deux émulateurs lors du chargement de la bannière. Admob est très explicite niveau logs

  4. #4
    Membre éclairé
    Homme Profil pro
    Inscrit en
    Mai 2012
    Messages
    535
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Mai 2012
    Messages : 535
    Par défaut
    rien de particulier à noter sauf 2 warnings:

    -> scheduling restart of crashedservice com.android.providers.media/.MtpService in 5000 Ms

    -> activity destroy timeout for ActivityRecord{41467c00 ukzzang.android.app.viewer/.act.MainAct

    sinon RAS, je vois passer les url google, tout a l'air de bien se passer...

  5. #5
    Membre éclairé
    Homme Profil pro
    Inscrit en
    Mai 2012
    Messages
    535
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Mai 2012
    Messages : 535
    Par défaut
    ce qui est surtout BIEN gonflant, c'est qu'aucun des exemples fournis par google (fundamentals, intermdediate, interstitial) ne fonctionne chez moi!

    TOUTES crashent, c'est qd même hallucinant............

  6. #6
    Membre éclairé
    Homme Profil pro
    Inscrit en
    Mai 2012
    Messages
    535
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Mai 2012
    Messages : 535
    Par défaut
    LOG EMULATOR
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
     
    10-04 12:39:38.600: E/Trace(1608): error opening trace file: No such file or directory (2)
    10-04 12:39:39.020: D/dalvikvm(1608): GC_FOR_ALLOC freed 55K, 3% free 8221K/8455K, paused 30ms, total 31ms
    10-04 12:39:39.180: D/dalvikvm(1608): GC_CONCURRENT freed 175K, 4% free 8561K/8839K, paused 78ms+4ms, total 141ms
    10-04 12:39:39.640: D/dalvikvm(1608): GC_CONCURRENT freed 113K, 2% free 8996K/9159K, paused 76ms+99ms, total 270ms
    10-04 12:39:39.640: D/dalvikvm(1608): WAIT_FOR_CONCURRENT_GC blocked 23ms
    10-04 12:39:39.650: D/dalvikvm(1608): WAIT_FOR_CONCURRENT_GC blocked 13ms
    10-04 12:39:39.790: I/Ads(1608): To get test ads on this device, call adRequest.addTestDevice(AdRequest.TEST_EMULATOR);
    10-04 12:39:39.860: I/Ads(1608): adRequestUrlHtml: <html><head><script src="http://media.admob.com/sdk-core-v40.js"></script><script>AFMA_getSdkConstants();AFMA_buildAdURL({"preqs":0,"session_id":"12614611658933535333","u_sd":1.5,"seq_num":"1","slotname":"\/xxxxxxx\/OUR_ADMOB_ID","u_w":320,"msid":"com.bidule.test","simulator":1,"cap":"a","js":"afma-sdk-a-v6.1.0","toar":0,"isu":"B3EEABB8EE11C2BE770B684D95219ECB","cipa":0,"format":"320x50_mb","net":"ed","app_name":"1.android.com.bidule.test","hl":"en","u_h":533,"carrier":"310260","testing":1,"ptime":0,"u_audio":4});</script></head><body></body></html>
    10-04 12:39:40.210: I/Choreographer(1608): Skipped 73 frames!  The application may be doing too much work on its main thread.
    10-04 12:39:40.220: D/dalvikvm(1608): GC_CONCURRENT freed 154K, 3% free 9352K/9607K, paused 80ms+114ms, total 271ms
    10-04 12:39:40.480: I/Choreographer(1608): Skipped 68 frames!  The application may be doing too much work on its main thread.
    10-04 12:39:40.500: D/gralloc_goldfish(1608): Emulator without GPU emulation detected.
    10-04 12:39:40.890: I/Choreographer(1608): Skipped 32 frames!  The application may be doing too much work on its main thread.
    10-04 12:39:43.150: I/Ads(1608): Received ad url: <url: "http://googleads.g.doubleclick.net:80/mads/gma?preqs=0&session_id=12614611658933535333&u_sd=1.5&slotname=a14e8f77524dde8&u_w=320&msid=com.bidule.test&cap=a&js=afma-sdk-a-v6.1.0&toar=0&isu=B3EEABB8EE11C2BE770B684D95219ECB&cipa=0&format=320x50_mb&net=ed&app_name=1.android.com.bidule.test&hl=en&u_h=533&carrier=310260&ptime=0&u_audio=4&u_so=p&adtest=on&output=html&region=mobile_app&u_tz=0&client_sdk=1&ex=1&caps=inlineVideo_interactiveVideo_mraid1_th_autoplay_mediation_sdkAdmobApiForAds_di&jsv=35" type: "admob" afmaNotifyDt: "null">
    10-04 12:39:44.670: D/webviewglue(1608): nativeDestroy view: 0x2a1a8ed0
    10-04 12:39:44.680: I/Ads(1608): onReceiveAd()
    10-04 12:39:44.880: D/dalvikvm(1608): GC_FOR_ALLOC freed 228K, 4% free 9473K/9799K, paused 127ms, total 129ms
    10-04 12:39:44.890: D/webviewglue(1608): nativeDestroy view: 0x2a1c3c88
    10-04 12:39:46.520: I/Choreographer(1608): Skipped 41 frames!  The application may be doing too much work on its main thread.
    10-04 12:39:48.230: W/IInputConnectionWrapper(1608): showStatusIcon on inactive InputConnection
    10-04 12:39:48.760: E/webview(1608): Error: WebView.destroy() called while still attached!
    10-04 12:39:48.770: D/webviewglue(1608): nativeDestroy view: 0x2a1c3c00
    LOG SAMSUNG
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
     
    10-04 13:50:21.420: D/dalvikvm(1372): GC_CONCURRENT freed 1715K, 69% free 2468K/7747K, paused 6ms+4ms, total 40ms
    10-04 13:50:21.860: D/Finsky(3094): [1] 5.onFinished: Installation state replication succeeded.
    10-04 13:50:25.310: D/AndroidRuntime(4912): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
    10-04 13:50:25.310: D/AndroidRuntime(4912): CheckJNI is OFF
    10-04 13:50:25.320: D/dalvikvm(4912): Trying to load lib libjavacore.so 0x0
    10-04 13:50:25.330: D/dalvikvm(4912): Added shared lib libjavacore.so 0x0
    10-04 13:50:25.330: D/dalvikvm(4912): Trying to load lib libnativehelper.so 0x0
    10-04 13:50:25.330: D/dalvikvm(4912): Added shared lib libnativehelper.so 0x0
    10-04 13:50:25.500: D/AndroidRuntime(4912): Calling main entry com.android.commands.pm.Pm
    10-04 13:50:25.580: D/AndroidRuntime(4912): Shutting down VM
    10-04 13:50:25.580: I/AndroidRuntime(4912): NOTE: attach of thread 'Binder_3' failed
    10-04 13:50:25.590: D/dalvikvm(4912): GC_CONCURRENT freed 103K, 82% free 474K/2560K, paused 1ms+0ms, total 5ms
    10-04 13:50:25.590: D/dalvikvm(4912): Debugger has detached; object registry had 1 entries
    10-04 13:50:25.970: D/AndroidRuntime(4925): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
    10-04 13:50:25.970: D/AndroidRuntime(4925): CheckJNI is OFF
    10-04 13:50:25.990: D/dalvikvm(4925): Trying to load lib libjavacore.so 0x0
    10-04 13:50:26.000: D/dalvikvm(4925): Added shared lib libjavacore.so 0x0
    10-04 13:50:26.010: D/dalvikvm(4925): Trying to load lib libnativehelper.so 0x0
    10-04 13:50:26.010: D/dalvikvm(4925): Added shared lib libnativehelper.so 0x0
    10-04 13:50:26.270: D/AndroidRuntime(4925): Calling main entry com.android.commands.am.Am
    10-04 13:50:26.280: I/ActivityManager(287): START {act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10000000 cmp=com.bidule.test/.VideGrenierMobi2 u=0} from pid 4925
    10-04 13:50:26.300: D/AndroidRuntime(4925): Shutting down VM
    10-04 13:50:26.310: I/AndroidRuntime(4925): NOTE: attach of thread 'Binder_3' failed
    10-04 13:50:26.310: D/dalvikvm(4925): GC_CONCURRENT freed 103K, 81% free 493K/2560K, paused 1ms+0ms, total 7ms
    10-04 13:50:26.320: D/dalvikvm(4925): Debugger has detached; object registry had 1 entries
    10-04 13:50:26.420: I/Ads(4875): To get test ads on this device, call adRequest.addTestDevice("2B8B585F92C97612132BB9768B2208A8");
    10-04 13:50:26.430: I/Ads(4875): adRequestUrlHtml: <html><head><script src="http://media.admob.com/sdk-core-v40.js"></script><script>AFMA_buildAdURL({"preqs":1,"session_id":"13367873792947739990","u_sd":1,"seq_num":"2","slotname":"\/xxxxxxx\/OUR_ADMOB_ID","u_w":800,"msid":"com.bidule.test","cap":"m","js":"afma-sdk-a-v6.1.0","toar":0,"mv":"8014017.com.android.vending","isu":"2B8B585F92C97612132BB9768B2208A8","cipa":0,"format":"320x50_mb","net":"wi","app_name":"1.android.com.bidule.test","hl":"fr","u_h":1232,"carrier":"","testing":1,"ptime":18774,"u_audio":1});</script></head><body></body></html>
    10-04 13:50:26.620: I/ActivityManager(287): Displayed com.bidule.test/.VideGrenierMobi2: +319ms
    10-04 13:50:26.860: I/Ads(4875): Received ad url: <url: "http://pubads.g.doubleclick.net:80/gampad/ads?u_sd=1&u_w=800&msid=com.bidule.test&cap=m&js=afma-sdk-a-v6.1.0&toar=0&mv=8014017.com.android.vending&isu=2B8B585F92C97612132BB9768B2208A8&cipa=0&net=wi&hl=fr&u_h=1232&carrier&testing=1&u_audio=1&u_so=p&output=html&region=mobile_app&u_tz=0&url=1.android.com.bidule.test.adsenseformobileapps.com&gdfp_req=1&markup=html&m_ast=afmajs&impl=ifr&correlator=3616067815750427&iu=%2F1034207%2Fagenda_vg_android&sz=320x50&caps=inlineVideo_interactiveVideo_mraid1_th_autoplay_mediation_sdkAdmobApiForAds_di&admob_cust_params=preqs%253D1%2526u_sd%253D1%2526u_w%253D800%2526msid%253Dcom.bidule.test%2526js%253Dafma-sdk-a-v6.1.0%2526hl%253Dfr%2526u_h%253D1232%2526ptime%253D18774%2526u_audio%253D1%2526u_so%253Dp%2526output%253Dhtml%2526region%253Dmobile_app%2526u_tz%253D0%2526caps%253DinlineVideo_interactiveVideo_mraid1_th_autoplay_mediation_sdkAdmobApiForAds_di&jsv=35" type: "xfp" afmaNotifyDt: "null">
    10-04 13:50:27.040: D/webviewglue(4875): nativeDestroy view: 0x2ac5b450
    10-04 13:50:27.040: I/Ads(4875): onFailedToReceiveAd(Ad request successful, but no ad returned due to lack of ad inventory.)
    10-04 13:50:32.330: W/IInputConnectionWrapper(4875): showStatusIcon on inactive InputConnection
    10-04 13:50:32.790: D/webviewglue(4875): nativeDestroy view: 0x2ac5b3b0

+ Répondre à la discussion
Cette discussion est résolue.

Discussions similaires

  1. Bad file number avec le manifest.xml
    Par Hypnos dans le forum Windows
    Réponses: 1
    Dernier message: 28/07/2011, 16h21
  2. Question sur le manifest.xml
    Par nagca dans le forum Android
    Réponses: 1
    Dernier message: 23/07/2011, 17h19
  3. manifest.xml + question sauvegarde données
    Par clement88 dans le forum Android
    Réponses: 6
    Dernier message: 07/03/2011, 16h48
  4. Réponses: 0
    Dernier message: 02/04/2009, 13h10
  5. Réponses: 11
    Dernier message: 02/02/2009, 08h47

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo