target-sdk

Can cordova android@6.2.3 target SDK 26?

守給你的承諾、 提交于 2019-12-08 09:33:55
问题 My app is currently running cordova-android@6.2.3. I am getting notices from Google that my app is currently targeting SDK 25 and that I need to target SDK 26. From Google: From August 2018, new apps must target at least Android 8.0 (API level 26). From November 2018, app updates must target Android 8.0 (API level 26). I have a few months for app updates to continue to work but I am going to run into a wall here shortly. Can I simply just add targetSdkVersion 26 and expect my app to work?

Android Studio shows methods from newer API

一个人想着一个人 提交于 2019-12-04 10:57:46
I have noticed that my Android Studio project is suggesting methods and types that are not available for use in my minimum SDK. I am using Android Studio version 1.1.0. I can see that my minimum SDK version is set correctly in the build.gradle file: android { compileSdkVersion 21 buildToolsVersion "21.1.2" defaultConfig { applicationId "com.pythagoras.sunshine" minSdkVersion 18 targetSdkVersion 21 versionCode 1 versionName "1.0" } ... } but I have noticed that the "auto-complete" feature in Android Studio still suggests methods that are not available in API 18. When I build the project I do

Can I run my app on API 23 if target SDK version I used is 21

血红的双手。 提交于 2019-12-02 06:54:33
问题 I have developed an Android App having API 21 as target SDK version. Will it run fine on API above it, for example, API 23? 回答1: It is perfectly ok to use a targetSdkVersion and install it on a device that has a greater SDK version. The targetSdkVersion that you specified in your build.gradle tells the system that you have developed and tested your app to work on that SDK. If the user installs your app on a greater SDK it is the system responsibility to provide backwards compatibility (if

confused about android runtime permissions

◇◆丶佛笑我妖孽 提交于 2019-12-02 06:11:03
问题 So this whole new android runtime permissions has gotten me confused. My app is currently compiling and targetting version 23 which means I have to use runtime permissions. My app primarily uses the camera api which needs the camera permission so I added the runtime permissions before opening the camera as such: if (ContextCompat.checkSelfPermission(this, Manifest.permission.CAMERA) != PackageManager.PERMISSION_GRANTED) {//ask permissions for camera ActivityCompat.requestPermissions(this, new

Android Q emulator - Build.VERSION.SDK_INT returns 28

梦想与她 提交于 2019-12-02 02:27:41
问题 Build.VERSION.SDK_INT returns 28 instead of 29 when running on Android Q emulator. Is there anything I am missing? I am trying to add logic specifically for Android Q but I do not know how to determine this version correctly. app.gradle file contains targetSdkVersion = 'Q' compileSdkVersion = 'android-Q' 回答1: Before the API is finalized and officially becomes API 29 (where you'd use compileSdkVersion 29 , etc), you must use BuildCompat.isAtLeastQ(): Checks if the device is running on a pre

confused about android runtime permissions

耗尽温柔 提交于 2019-12-02 01:08:39
So this whole new android runtime permissions has gotten me confused. My app is currently compiling and targetting version 23 which means I have to use runtime permissions. My app primarily uses the camera api which needs the camera permission so I added the runtime permissions before opening the camera as such: if (ContextCompat.checkSelfPermission(this, Manifest.permission.CAMERA) != PackageManager.PERMISSION_GRANTED) {//ask permissions for camera ActivityCompat.requestPermissions(this, new String[]{Manifest.permission.CAMERA}, CameraPermissions); } else {//permissions attained now you can

SYSTEM_ALERT_WINDOW - How to get this permission automatically on Android 6.0 and targetSdkVersion 23

纵然是瞬间 提交于 2019-11-26 03:24:35
问题 Facebook, Evernote, Pocket - all apps get this permission on Android 6.0 automatically, even though they are targeting 23 ( targetSdkVersion=23 ). There has been a lot of documentation regarding the new Marshmallow permission model. One of them is SYSTEM_ALERT_WINDOW been \'promoted\' to \'above dangerous\' permission class thus requiring a special user intervention in order for apps to be granted with those. If the app has targetSdkVersion 22 or lower, app gets this permission automatically

SYSTEM_ALERT_WINDOW - How to get this permission automatically on Android 6.0 and targetSdkVersion 23

喜欢而已 提交于 2019-11-26 00:37:27
Facebook, Evernote, Pocket - all apps get this permission on Android 6.0 automatically, even though they are targeting 23 ( targetSdkVersion=23 ). There has been a lot of documentation regarding the new Marshmallow permission model. One of them is SYSTEM_ALERT_WINDOW been 'promoted' to 'above dangerous' permission class thus requiring a special user intervention in order for apps to be granted with those. If the app has targetSdkVersion 22 or lower, app gets this permission automatically (if requested in the manifest). However, I've noticed some apps that get this permission, without needing