2017-03-28 1 views
0

Here is screen of my app, this working before i upgrade some of gradle files version구글지도 Gradle을 버전으로 업그레이드 한 후 표시를 중지입니다

우는 내 매니페스트 나의 Gradle을가

compileSdkVersion 24 
buildToolsVersion "24.0.0" 


dependencies { 
compile fileTree(include: ['*.jar'], dir: 'libs') 
compile project(':DatePicker') 
compile project(':agendacalendarview') 
compile files('libs/acra-4.5.0.jar') 
compile project(':MaterialCalenderView') 
compile 'com.getbase:floatingactionbutton:1.10.1' 
compile 'com.sothree.slidinguppanel:library:3.3.0' 
compile 'com.getbase:floatingactionbutton:1.10.1' 
compile 'com.sothree.slidinguppanel:library:3.3.0' 
compile 'com.android.support:design:24.2.1' 
compile 'de.hdodenhof:circleimageview:2.0.0' 
compile 'com.android.support:cardview-v7:24.2.1' 
compile 'com.hbb20:ccp:1.4' 
compile 'com.github.scottyab:showhidepasswordedittext:0.8' 
compile 'com.vistrav:ask:2.4' 
compile 'com.nostra13.universalimageloader:universal-image-loader:1.9.5' 
compile 'com.android.volley:volley:1.0.0' 
compile 'org.apache.httpcomponents:httpcore:4.4.1' 
compile 'org.apache.httpcomponents:httpclient:4.5' 
compile 'org.apache.httpcomponents:httpmime:4.2.3' 

compile 'com.squareup.retrofit2:retrofit:2.0.2' 
compile 'com.squareup.retrofit2:converter-gson:2.0.2' 
compile 'com.squareup.okio:okio:1.7.0' 
compile 'com.squareup.okhttp3:okhttp:3.2.0' 
compile 'com.google.code.gson:gson:2.7' 
compile 'org.apmem.tools:layouts:[email protected]' 
compile 'com.google.firebase:firebase-messaging:10.0.1' 
compile 'com.android.support:support-v4:24.2.1' 
compile 'com.mani:ThinDownloadManager:1.2.4' 
compile 'com.jakewharton:butterknife:7.0.0' 
compile 'com.google.android.gms:play-services-maps:10.0.1' 
compile 'com.github.lzyzsd:circleprogress:[email protected]' 
compile 'com.squareup.okhttp3:logging-interceptor:3.2.0' 
compile 'com.tbuonomo:slidingpuzzleloading:1.0.1' 
testCompile 'junit:junit:4.12' 

}

을 파일 메타 데이터 여기

<meta-data 
     android:name="com.google.android.gms.version" 
     android:value="@integer/google_play_services_version" /> 
    <meta-data 
     android:name="com.google.android.maps.v2.API_KEY" 
     android:value="HERE IS MY API KEY" /> 

파일입니다,363,210

하는 플러그인을 적용 'com.google.gms.google-서비스'여기

내가 MAP API

에서 모든 최신 코드를 업그레이드하려고 노력하지만 그건

dependencies { 
    classpath 'com.android.tools.build:gradle:2.2.3' 
    classpath 'com.google.gms:google-services:3.0.0' 
    classpath 'me.tatarka:gradle-retrolambda:3.1.0' 

    // NOTE: Do not place your application dependencies here; they belong 
    // in the individual module build.gradle files 
} 

내 프로젝트 Gradle을하다 지금 일하지 않아. 또한 내가 사용하고 안드로이드 스튜디오 버전 2.3 여기

공용 클래스 MapsActivity이 FragmentActivity이 MAP에 대한 {

private GoogleMap mMap; 

@Override 
protected void onCreate(Bundle savedInstanceState) { 
    super.onCreate(savedInstanceState); 
    setContentView(R.layout.activity_maps); 
    // Obtain the SupportMapFragment and get notified when the map is ready to be used. 
    SupportMapFragment mapFragment = (SupportMapFragment) getSupportFragmentManager() 
      .findFragmentById(R.id.map); 
    mapFragment.getMapAsync(this); 
} 

@Override 
public void onMapReady(GoogleMap googleMap) { 
    mMap = googleMap; 

    // Add a marker in Sydney and move the camera 
    LatLng sydney = new LatLng(-34, 151); 
    mMap.addMarker(new MarkerOptions().position(sydney).title("Marker in Sydney")); 
    mMap.moveCamera(CameraUpdateFactory.newLatLng(sydney)); 
} 

}

XML OnMapReadyCallback를 구현 확장에만 MAP 내 응용 프로그램 코드입니다 보기

<fragment xmlns:android="http://schemas.android.com/apk/res/android" 
xmlns:map="http://schemas.android.com/apk/res-auto" 
xmlns:tools="http://schemas.android.com/tools" 
android:id="@+id/map" 
android:name="com.google.android.gms.maps.SupportMapFragment" 
android:layout_width="match_parent" 
android:layout_height="match_parent" 
tools:context="com.squincy.inhup.Activity.MapsActivity" /> 
+0

지도를 표시하기위한 코드를 추가하십시오. –

+0

컴퓨터를 바꿨을 거 같네요, 그렇죠? –

+0

Google지도 코드를 추가하십시오. –

답변

0

안녕하세요 @ pmrajnai13 Google지도 API 키가 AndroidManifest.xml 파일에 없습니다. Google지도 API를 추가하십시오.

+0

안녕하세요 @vinod 나는 원래 코드에 키를 넣었습니다. – pmrajnai13

관련 문제