谷歌地图V2 Android的地图参考 [英] Google Map V2 android map referencing

查看:123
本文介绍了谷歌地图V2 Android的地图参考的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图安装谷歌地图Android版。我看到两个变焦按钮,但得到地图没有显示。我一直在苦苦挣扎,去年6-7小时。此前据示值误差(未开放)及现在它没有显示在地图上。

I'm trying to setup google map for android. I'm seeing the two zoom buttons but no map is getting displayed. I've been struggling hard for last 6-7 hours. Earlier it was showing error (wasn't opening up) & now it's not showing the map.

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.counz.app"
android:versionCode="1"
android:versionName="1.0" >

<uses-sdk
    android:minSdkVersion="8"
    android:targetSdkVersion="16" />

<permission
    android:name="com.example.mapdemo.permission.MAPS_RECEIVE"
    android:protectionLevel="signature" />

<uses-feature
    android:glEsVersion="0x00020000"
    android:required="true" />

<uses-permission android:name="com.example.mapdemo.permission.MAPS_RECEIVE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

<application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <activity
        android:name="com.counz.app.MainActivity"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <meta-data
        android:name="com.google.android.maps.v2.API_KEY"
        android:value="(mykey)" />
</application>

编辑:这是LogCat中误差

This is the LogCat error

  03-09 23:15:47.210: W/KeyCharacterMap(14440): Using default keymap: /system/usr/keychars/qwerty.kcm.bin
03-09 23:16:24.740: W/dalvikvm(14545): VFY: unable to resolve instance field 23
03-09 23:16:25.540: W/dalvikvm(14545): Unable to resolve superclass of Lmaps/p/s; (427)
03-09 23:16:25.540: W/dalvikvm(14545): Link of class 'Lmaps/p/s;' failed
03-09 23:16:25.540: W/dalvikvm(14545): Unable to resolve superclass of Lmaps/y/bo; (3820)
03-09 23:16:25.540: W/dalvikvm(14545): Link of class 'Lmaps/y/bo;' failed
03-09 23:16:25.540: W/dalvikvm(14545): Unable to resolve superclass of Lmaps/i/k; (4208)
03-09 23:16:25.540: W/dalvikvm(14545): Link of class 'Lmaps/i/k;' failed
03-09 23:16:25.540: E/dalvikvm(14545): Could not find class 'maps.i.k', referenced from method maps.z.ag.a
03-09 23:16:25.540: W/dalvikvm(14545): VFY: unable to resolve new-instance 3540 (Lmaps/i/k;) in Lmaps/z/ag;
03-09 23:16:29.020: I/ActivityThread(14545): queueIdle
03-09 23:16:29.060: V/ActivityThread(14545): Reporting idle of ActivityRecord{4a4a9288 token=android.os.BinderProxy@4a4a8df8 {com.counz.app/com.counz.app.MainActivity}} finished=false
03-09 23:16:29.060: W/ActivityNative(14545): send ACTIVITY_IDLE_TRANSACTION
03-09 23:16:29.750: E/Google Maps Android API(14545): Authorization failure.
03-09 23:16:58.600: I/ActivityThread(14545): queueIdle
03-09 23:16:58.600: V/ActivityThread(14545): Reporting idle of ActivityRecord{4a4a9288 token=android.os.BinderProxy@4a4a8df8 {com.counz.app/com.counz.app.MainActivity}} finished=false
03-09 23:16:58.600: W/ActivityNative(14545): send ACTIVITY_IDLE_TRANSACTION

感谢。 :)

Thanks. :)

推荐答案

您做参考走错路了,请看看这短短的8个步骤指南,我写信给让你的应用程序中的谷歌地图,请跟随步骤precisely,你将有一个谷歌地图在最后。

You doing the referencing the wrong way, please take a look at this short 8 steps guide that i wrote to get a Google map in your application, please follow the steps precisely and you will have a Google map at the end.

我创建一个谷歌地图应用程序,当我在写这篇指南,你可以在它结束时看到的最终结果。

I was creating a Google map application when i was writing this guide and you can see the end result at it end.

创建谷歌地图API V2

这篇关于谷歌地图V2 Android的地图参考的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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