androidx

I want to import design library in androidx 29 version(latest version)

我与影子孤独终老i 提交于 2020-01-24 01:57:13
问题 Below image clarify my question. I was try multiples of times to import design library in android studio lastest version 29 (android x) but library does'nt work kindly tell me the design library for androidx 29. 回答1: You can use : - implementation 'com.google.android.material:material:1.0.0' library in androidx for design. 回答2: The library androidx.design:design:1.0.0 doesn't exist . You have to use the Material Components library. Material Components for Android is a drop-in replacement for

Manifest merger failed with Firebase Auth

风流意气都作罢 提交于 2020-01-22 16:33:25
问题 When I implement implementation 'com.google.firebase:firebase-core:17.0.0' implementation 'com.google.firebase:firebase-auth:18.0.0' The Manifest not Sync, Error message like this: ERROR: Manifest merger failed : Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91 is also present at [androidx.core:core:1.0.0] AndroidManifest.xml:22:18-86 value=(androidx.core.app

No tests found when running instrumented tests with AndroidX

陌路散爱 提交于 2020-01-21 11:49:07
问题 I'm trying to run the standard ExampleInstrumentedTest in my Android project (which uses AndroidX), but get "No tests found" error instead. I've looked through the other questions and the documentation and I'm pretty sure I've done everything right, but maybe I'm overlooking anything? Here is my app's build.gradle: apply plugin: 'com.android.application' apply plugin: 'kotlin-android' apply plugin: 'kotlin-kapt' android { compileSdkVersion 28 defaultConfig { minSdkVersion 24 targetSdkVersion

PreferenceActivity: getFragmentManager() has been deprecated

非 Y 不嫁゛ 提交于 2020-01-20 06:54:06
问题 when testing a android.preference.PreferenceActivity, I get the following warning: warning: [deprecation] getFragmentManager() in Activity has been deprecated that is how I obtain a handle to the current PreferenceFragment : FragmentManager fm = this.mActivity.getFragmentManager(); this.currentFragment = (PreferenceFragment) fm.getFragments().get(1); using FragmentActivity.getSupportFragmentManager() is obviously not an option. found PreferenceFragmentCompat, which would replace the

PreferenceActivity: getFragmentManager() has been deprecated

故事扮演 提交于 2020-01-20 06:54:05
问题 when testing a android.preference.PreferenceActivity, I get the following warning: warning: [deprecation] getFragmentManager() in Activity has been deprecated that is how I obtain a handle to the current PreferenceFragment : FragmentManager fm = this.mActivity.getFragmentManager(); this.currentFragment = (PreferenceFragment) fm.getFragments().get(1); using FragmentActivity.getSupportFragmentManager() is obviously not an option. found PreferenceFragmentCompat, which would replace the

How to zoom the preview using Android CameraX library?

房东的猫 提交于 2020-01-14 14:35:33
问题 I hope to add a function to zoom in preview picture (Please see Image A ) for the sample code at https://github.com/android/camera/tree/master/CameraXBasic I have read the article but the following code doesn't work. How can I zoom the preview with CameraX API 1.0.0-alpha05 ? CameraFragment.kt /** Declare and bind preview, capture and analysis use cases */ private fun bindCameraUseCases() { ... // Apply declared configs to CameraX using the same lifecycle owner CameraX.bindToLifecycle(

Display back button on toolbar on first screen of navigation graph

牧云@^-^@ 提交于 2020-01-12 09:50:47
问题 I'm trying out androidx navigation component and have setup my activity with a toolbar a container. I'm doing this in one of the intermittent screens of my app which has a lot of internal navigation/steps and I thought I could navigation arch component a try with this. Since this is an intermittent screen, I want to display a back button on the toolbar from the first screen itself. I've already setup the toolbar with the below code in the onCreate() method of my host activity,

AppBarLayout inflating error after migrating to AndroidX

北战南征 提交于 2020-01-12 07:47:26
问题 When migrating to AndroidX I faced this problem: Java.lang.RuntimeException: Unable to start activity ComponentInfo{com.mandarine.android/com.mandarine.android.features.root.RootActivity}: android.view.InflateException: Binary XML file line #18: Binary XML file line #18: Error inflating class android.support.design.widget.AppBarLayout 回答1: Unless you implement the old support libraries and enable Jetifier, you have to rename all your support classes in XML. android.support.design.widget

Why won't androidx support the navigation bar?

ⅰ亾dé卋堺 提交于 2020-01-11 14:36:18
问题 So I'm trying to get a navigation drawer done using this tutorial (https://www.youtube.com/watch?v=fGcMLu1GJEc&t=16s) however, I undersetand that something has changed in Android Studio since the tutorial was uploaded with AndroidX and toolbars and stuff, but I'm not sure what has changed. I've been trying for hours to understand the problem but I'm new to android studio so I'm clueless. The app just keeps crashing Basically, I just don't know what to import in regards to the toolbar to make

Flutter app freeze in build release, work properly in debug, androidX?

泪湿孤枕 提交于 2020-01-06 14:28:18
问题 final update: now everything works; while before I was not adding internet permission and the app worked perfectly (contacting API and everything), since the update I have to explicitly modify the manifest. Easy fix actually: manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.xxx.xxx"> <uses-permission android:name="android.permission.INTERNET"/> <application android:name="io.flutter.app.FlutterApplication" android:label="xxx" android:icon="@mipmap/ic_launcher">