개발235 [Android] compile, testCompile compile 에서 implementation 과 api 로 변경되었다고 함. 보통 compile 을 implementation 으로 변경해주면 된다. api 는 특별한 상황에 쓰이는 것으로 생각된다. (자세한 것은 검색을 통할 것) testCompile 부분도 마찬가지로 implementation 으로 변경해준다. testCompile 'junit:junit:4.12'을 아래와 같이 변경해도 별 문제 없다. testImplementation 'junit:junit:4.12' 참고https://developer.android.com/studio/build/dependencies?utm_source=android-studio#dependency_configurationshttps://medium.com/m.. 2019. 2. 21. [Android][kotlin] kotlin 에서 문자열 붙이기 변경점 + map.put 방식 변경 kotlin 에서 문자열 붙이기가.. $ 를 이용한 방식으로 바뀐 것 같다. 아래는 예시) Log.e("가나다라 $msg") Log.e("$msg 가나다라") 변수명 바로 앞에 $ 표시를 붙여줘서, 문자열 안에서 사용할 수 있게 한 것으로 보인다. 아마도 짐작을 해보면, 결국은 toString 을 해서 연결하고 붙이는 과정이 내부적으로 일어날 것 같다. map.put 의 방식에서 변화. ITEM_MAP.put(item.id, item) // 위에서 아래와 같이 변경 ITEM_MAP[item.id] = item 2019. 2. 21. [Android] Warning : Download https://dl.google.com/dl/android/maven2/com/google/firebase/firebase-measurement-connector-impl/17.0.5/firebase-measurement-connector-impl-17.0.5-javadoc.jar Download https://dl.google.com/dl/android/maven2/com/google/firebase/firebase-measurement-connector-impl/17.0.5/firebase-measurement-connector-impl-17.0.5-javadoc.jar https://stackoverflow.com/questions/54601501/could-not-get-resource-http-firebase-measurement-connector-impl-17-0-5-jav gradle 파일의 버전을 5.x 이상으로 올려야 한다고 함. 2019. 2. 21. [안드로이드 Android] API 'variant.getExternalNativeBuildTasks()' is obsolete and has been replaced with 'variant.getExternalNativeBuildProviders()'. (수정 2019-03-12) 개요 (아래는 메시지 내용) API 'variant.getExternalNativeBuildTasks()' is obsolete and has been replaced with 'variant.getExternalNativeBuildProviders()'. It will be removed at the end of 2019. For more information, see https://d.android.com/r/tools/task-configuration-avoidance. To determine what is calling variant.getExternalNativeBuildTasks(), use -Pandroid.debug.obsoleteApi=true on the command line to d.. 2019. 2. 21. [Android] gradle 버전 올릴 때. 1) classpath 'com.android.tools.build:gradle:3.2.1'의 버전을 수정 2) https://developer.android.com/studio/releases/gradle-plugin 을 확인해서, 'Requiered Gradle version' 을 높일 필요가 있다면, gradle-wrapper.properties 에서 distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip 의 버전을 수정. 3) crashlytics 를 사용 중이라면, 때때로, classpath 'io.fabric.tools:gradle:1.25.4' 의 버전을 바꿀 필요가 생김. (그런 경우 알림이 뜸) 4)때때로.. 2019. 2. 21. [Android] 구글 Firebase Crashlytics 와 연관된 설정 (업데이트 2019-03-06) 개요구글 Firebase 의 Crashlyrics 를 추가하기 위한 설정을 다룹니다. 자세한 것은 firebase 의 링크에서 확인할 수 있습니다. 본문 project 수준 build.gradle buildscript > repositories 에 추가함 maven { url 'https://maven.fabric.io/public' } buildscript > dependencies 에 추가함 classpath 'com.google.gms:google-services:4.2.0' classpath 'io.fabric.tools:gradle:1.27.1' allprojects > repositories 에 추가함 maven { url 'https://maven.google.com/' } app 수준 bu.. 2019. 2. 21. [안드로이드 Android] The Google Mobile Ads SDK was initialized incorrectly. (수정 2019-03-11) 개요java.lang.RuntimeException: Unable to get provider com.google.android.gms.ads.MobileAdsInitProvider: java.lang.IllegalStateException: 어느 날 위와 같은 에러 로그가 생겨서, 검색해서 알아보게 되었습니다. 본문AndroidManifest.xml 에서 안에 이 있는데, 그 안에 밑에 다음과 같은 것을 추가해주면 됩니다. Google Ads SDK 17.0.0 이상에서는 추가해야 한다고 합니다. 참고 주소https://stackoverflow.com/questions/52786963/unable-to-get-provider-com-google-android-gms-ads-mobileadsinitpro.. 2019. 2. 21. [Android] com.android.support:appcompat-v7:27.0.1 버전 혼동 문제. 본문 com.android.support:appcompat-v7:27.0.1 버전 혼동 문제. com.android.support:customtabs:26.1.0 으로 버전이 다르다고 함. https://stackoverflow.com/questions/50009286/gradle-mixing-versions-27-1-1-and-26-1-0 implementation 'com.android.support:customtabs:27.0.1' 직접 지정하는 방식을 추가하라고 함. 결론 implementation 'com.android.support:customtabs:27.0.1'와 같은 부분을 추가함. 정확히 저게 어디 쓰이는 지는 모르겠음.. 2019. 2. 21. [Android] kotlin-stdlib-jre7 is deprecated. Please use kotlin-stdlib-jdk7 instead implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"=>implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" jre -> jdk 로 변경 별 문제 없음 2019. 2. 21. [Android] Missing accessibility label: in Android Studio Warning tools:ignore="LabelFor" 와 같이 추가하면 된다고 함. https://stackoverflow.com/questions/52868488/missing-accessibility-label-in-android-studio-warning 2019. 2. 21. 이전 1 ··· 3 4 5 6 7 8 9 ··· 24 다음