| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 import 'dart:sky' as sky; | 5 import 'dart:sky' as sky; |
| 6 | 6 |
| 7 import '../rendering/box.dart'; | 7 import 'package:sky/rendering/box.dart'; |
| 8 import '../rendering/object.dart'; | 8 import 'package:sky/rendering/object.dart'; |
| 9 import '../theme/view_configuration.dart'; | 9 import 'package:sky/theme/view_configuration.dart'; |
| 10 import 'widget.dart'; | 10 import 'package:sky/widgets/widget.dart'; |
| 11 | 11 |
| 12 // Slots are painted in this order and hit tested in reverse of this order | 12 // Slots are painted in this order and hit tested in reverse of this order |
| 13 enum ScaffoldSlots { | 13 enum ScaffoldSlots { |
| 14 body, | 14 body, |
| 15 statusBar, | 15 statusBar, |
| 16 toolbar, | 16 toolbar, |
| 17 snackBar, | 17 snackBar, |
| 18 floatingActionButton, | 18 floatingActionButton, |
| 19 drawer | 19 drawer |
| 20 } | 20 } |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 223 super.syncRenderObject(old); | 223 super.syncRenderObject(old); |
| 224 for (ScaffoldSlots slot in ScaffoldSlots.values) { | 224 for (ScaffoldSlots slot in ScaffoldSlots.values) { |
| 225 Widget widget = _slots[slot]; | 225 Widget widget = _slots[slot]; |
| 226 _slots[slot] = syncChild(widget, old is Scaffold ? old._slots[slot] : null
, slot); | 226 _slots[slot] = syncChild(widget, old is Scaffold ? old._slots[slot] : null
, slot); |
| 227 assert((_slots[slot] == null) == (widget == null)); | 227 assert((_slots[slot] == null) == (widget == null)); |
| 228 assert(_slots[slot] == null || _slots[slot].parent == this); | 228 assert(_slots[slot] == null || _slots[slot].parent == this); |
| 229 } | 229 } |
| 230 } | 230 } |
| 231 | 231 |
| 232 } | 232 } |
| OLD | NEW |