android-8.0-oreo

Parent Activity is recreating after calling Camera intent in Android Oreo

半世苍凉 提交于 2021-02-05 10:51:48
问题 I am using Media intent capturing image. Once process completed result will be send back to parent. Above mentioned process working properly up to Nougat Os but in Oreo the parent activity is recreating again. How can i solve this issue. 回答1: Above mentioned process working properly up to Nougat Os but in Oreo the parent activity is recreating again Your process is being terminated while the camera app is in the foreground. This is perfectly normal and has nothing to do with Android 8.0. It

Parent Activity is recreating after calling Camera intent in Android Oreo

允我心安 提交于 2021-02-05 10:51:32
问题 I am using Media intent capturing image. Once process completed result will be send back to parent. Above mentioned process working properly up to Nougat Os but in Oreo the parent activity is recreating again. How can i solve this issue. 回答1: Above mentioned process working properly up to Nougat Os but in Oreo the parent activity is recreating again Your process is being terminated while the camera app is in the foreground. This is perfectly normal and has nothing to do with Android 8.0. It

Android Oreo 8.0 Native C++ crash: invalid pthread_t passed to libc

丶灬走出姿态 提交于 2021-01-27 18:47:28
问题 I have an Android Application that uses Cmake to compile native code into my application, and it was working great on A Pixel device running Android 7.1. I decided to upgrade my Pixel device to Oreo 8.0 and now I cannot enter the native C++ code in my app. This is the logcat dump when it crashes: A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** A/DEBUG: Build fingerprint: 'google/sailfish/sailfish:8.0.0/OPR3.170623.007/4286350:user/release-keys' A/DEBUG: Revision: '0'

Broadcast receiver for nought and Oreo + devices not working

青春壹個敷衍的年華 提交于 2021-01-27 18:22:34
问题 public class ScreenReceiver extends BroadcastReceiver { private boolean screenOff; @Override public void onReceive(Context context, Intent intent) { if (intent.getAction().equals(Intent.ACTION_SCREEN_OFF)) { screenOff = true; } else if (intent.getAction().equals(Intent.ACTION_SCREEN_ON)) { screenOff = false; } } <receiver android:name=".ScreenReceiver" android:enabled="true" android:exported="true"> <intent-filter> <action android:name="android.intent.action.PHONE_STATE" /> <action android

“Not enough information to infer parameter T” with Kotlin and Android

强颜欢笑 提交于 2021-01-19 12:45:58
问题 I'm trying to replicate the following ListView in my Android app using Kotlin: https://github.com/bidrohi/KotlinListView. Unfortunately I'm getting an error I'm unable to resolve myself. Here's my code: MainActivity.kt: override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) setContentView(R.layout.activity_main) val listView = findViewById(R.id.list) as ListView listView.adapter = ListExampleAdapter(this) } private class ListExampleAdapter(context: Context) :

How to call constructor of parent class when the default constructor is deprecated

有些话、适合烂在心里 提交于 2021-01-07 01:41:11
问题 I have a class called BaseKeyListener that extends android.text.method.DigitsKeyListener. I didn't define a constructor in the BaseKeyListener class so the parents default constructor was called. As of api level 26 the default constructor of DigitsKeyListener is deprecated. In order to still support lower Android versions I would have to add a constructor to BaseKeyListener that conditionally calls the constructor of the parent. However this results in another error. public static abstract

How to check if the device has Low Storage on Android Oreo API 26 and Above

不问归期 提交于 2020-12-29 13:23:08
问题 How can I check if the device has low storage on Android 8 Oreo. I saw in the Android Documentation that the Intent.ACTION_DEVICE_STORAGE_LOW is deprecated in API 26. This constant was deprecated in API level 26. if your app targets O or above, this broadcast will no longer be delivered to any BroadcastReceiver defined in your manifest. Instead, apps are strongly encouraged to use the improved getCacheDir() behavior so the system can automatically free up storage when needed. - Android