flutter local_auth plugin requires activity to be a FragmentActivity 如何解决

发布于 1周前 作者 phonegap100 来自 问答

flutter local_auth plugin requires activity to be a FragmentActivity 如何解决

1 回复

找到 MainActivity

package com.itying.flutter_app

import androidx.annotation.NonNull;
//import io.flutter.embedding.android.FlutterActivity
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);
    }
}

回到顶部