Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to fingerprint login to Android phone #27

Open
wangtingtingdvdsv opened this issue Nov 12, 2019 · 2 comments
Open

How to fingerprint login to Android phone #27

wangtingtingdvdsv opened this issue Nov 12, 2019 · 2 comments

Comments

@wangtingtingdvdsv
Copy link

How to register your fingerprint and log in with your fingerprint

rodydavis added a commit that referenced this issue Jan 31, 2020
@bo-feng-it
Copy link

bo-feng-it commented Nov 20, 2020

How to register your fingerprint and log in with your fingerprint

the same question...

Exception occurred as below, though I have added <uses-permission android:name="android.permission.USE_FINGERPRINT"/> to src/main/AndroidManifest.xml.

I/flutter (13327): PlatformException(no_fragment_activity, local_auth plugin requires activity to be a FragmentActivity., null, null)

@bo-feng-it
Copy link

Resolved.

Use FlutterFragmentActivity instead of FlutterActivity in MainActivity.kt, and it works.

//import io.flutter.embedding.android.FlutterActivity
import androidx.annotation.NonNull
import io.flutter.embedding.android.FlutterFragmentActivity
import io.flutter.embedding.engine.FlutterEngine
import io.flutter.plugins.GeneratedPluginRegistrant

class MainActivity: FlutterFragmentActivity() {
    override fun configureFlutterEngine(@NonNull flutterEngine: FlutterEngine) {
        GeneratedPluginRegistrant.registerWith(flutterEngine)
    }
}

Reference: flutter/flutter#33429

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants