mirror of
https://github.com/flutter/flutter.git
synced 2026-02-12 05:42:27 +08:00
Merge pull request #747 from collinjackson/fitness_loading
Don’t flash a message while fitness data is loading
This commit is contained in:
commit
ca42e8865d
@ -214,6 +214,8 @@ class FeedFragment extends StatefulComponent {
|
||||
|
||||
Widget buildBody() {
|
||||
TextStyle style = Theme.of(this).text.title;
|
||||
if (userData == null)
|
||||
return new Material(type: MaterialType.canvas);
|
||||
if (userData.items.length == 0)
|
||||
return new Material(
|
||||
type: MaterialType.canvas,
|
||||
|
||||
@ -86,7 +86,7 @@ class UserDataImpl extends UserData {
|
||||
|
||||
class FitnessApp extends App {
|
||||
NavigationState _navigationState;
|
||||
UserDataImpl _userData = new UserDataImpl();
|
||||
UserDataImpl _userData;
|
||||
|
||||
void didMount() {
|
||||
super.didMount();
|
||||
|
||||
@ -425,10 +425,14 @@ abstract class TagNode extends Widget {
|
||||
void _sync(Widget old, dynamic slot) {
|
||||
Widget oldChild = old == null ? null : (old as TagNode).child;
|
||||
child = syncChild(child, oldChild, slot);
|
||||
assert(child.parent == this);
|
||||
assert(child.renderObject != null);
|
||||
_renderObject = child.renderObject;
|
||||
assert(_renderObject == renderObject); // in case a subclass reintroduces it
|
||||
if (child != null) {
|
||||
assert(child.parent == this);
|
||||
assert(child.renderObject != null);
|
||||
_renderObject = child.renderObject;
|
||||
assert(_renderObject == renderObject); // in case a subclass reintroduces it
|
||||
} else {
|
||||
_renderObject = null;
|
||||
}
|
||||
}
|
||||
|
||||
void updateSlot(dynamic newSlot) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user