我在我的应用程序中显示一些动画自定义画家进度条,它显示一些错误
Error: The following assertion was thrown while notifying listeners for AnimationController:
'package:flutter/src/widgets/framework.dart': Failed assertion: line 4263 pos 12: '_debugLifecycleState != _ElementLifecycle.defunct': is not true.
Run Code Online (Sandbox Code Playgroud)
我有一个简单的主页,其中有一个导航栏。当导航发生这样的变化时,我只是显示容器
SingleChildScrollView(
child: Container(
decoration: BoxDecoration(
image: DecorationImage(
image: AssetImage("images/sidebg.png"),
fit: BoxFit.cover,
),
),
child: Column(
children: [
pageIndex == 0 ? DashboardScreen() : Container(),
pageIndex == 1 ? MapScreen() : Container(),
pageIndex == 3 ? ServiceCenter() : Container(),
pageIndex == 4 ? ProfileScreen() : Container(),
],
)),
),
Run Code Online (Sandbox Code Playgroud)
问题是,当索引更改时,您可以看到页面发生更改,但是当我更改页面时,它会显示错误,正如我上面在持续循环中提到的那样,不会停止。
如果我删除这个进度指示器,一切都会正常工作。
这是进度指示器屏幕
import 'dart:math' as …Run Code Online (Sandbox Code Playgroud) 简单的问题,\n很难解决(我认为),
\n当我启动 main.dart 时出现此错误:
\nError:\n Overlay manifest:package attribute declared at AndroidManifest.xml:2:5-34 value=(com.example.Scanner)\n has a different value=(com.example.Scanner) declared in main manifest at AndroidManifest.xml:1:70-97\n Suggestion: remove the overlay declaration at AndroidManifest.xml and place it in the build.gradle:\n flavorName {\n applicationId = "com.example.Scanner"\n }\n\nFAILURE: Build failed with an exception.\nRun Code Online (Sandbox Code Playgroud)\n这是我的 build.gradle:
\n defaultConfig {\n // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).\n applicationId="com.example.Scanner"\n minSdkVersion 16\n targetSdkVersion 29\n versionCode flutterVersionCode.toInteger()\n versionName flutterVersionName\n }\nRun Code Online (Sandbox Code Playgroud)\n这是我的 AndroidManifest.xml:
\npackage="com.example.Scanner">\nRun Code Online (Sandbox Code Playgroud)\n我希望有人可以帮助我,否则我就不能再在这个应用程序中\xc2\xb4t编程了:( …