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

appbar error #1

Closed
naiiu opened this issue Dec 17, 2018 · 2 comments
Closed

appbar error #1

naiiu opened this issue Dec 17, 2018 · 2 comments

Comments

@naiiu
Copy link

naiiu commented Dec 17, 2018

Compiler message:
lib/main.dart:25:15: Error: The argument type '#lib1::CustomAppBar' can't be assigned to the parameter type '#lib2::PreferredSizeWidget'.
Try changing the type of the parameter, or casting the argument to '#lib2::PreferredSizeWidget'.
appBar: CustomAppBar(),
^
Compiler failed on C:\Users\shaoz\Downloads\flightapp-master\lib\main.dart
Gradle task assembleDebug failed with exit code 1

@pburel
Copy link

pburel commented Dec 17, 2018

Could be:
//appBar: CustomAppBar(),
bottomNavigationBar: PreferredSize(
preferredSize: Size.fromHeight(50.0), // here the desired height
child: CustomAppBar(
// ...
),
),

@TechieBlossom
Copy link
Owner

@pburel is right, but with a slight correction.
bottomNavigationBar: CustomAppBar().

in next code push, I will definitely update it.

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

3 participants