mirror of
https://github.com/flutter/samples.git
synced 2025-11-13 10:59:04 +00:00
Samples maintenance (#435)
This commit is contained in:
@@ -59,16 +59,16 @@ class _DataTreeInkWellState extends State<DataTreeInkWell>
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final ColorScheme colorScheme = Theme.of(context).colorScheme;
|
||||
final colorScheme = Theme.of(context).colorScheme;
|
||||
|
||||
final Animation<Color> backgroundColor = controller
|
||||
final backgroundColor = controller
|
||||
.drive(CurveTween(curve: Curves.fastOutSlowIn))
|
||||
.drive(ColorTween(
|
||||
begin: colorScheme.primary.withOpacity(0.0),
|
||||
end: colorScheme.primary.withOpacity(0.08),
|
||||
));
|
||||
|
||||
final Animation<Color> iconColor = controller
|
||||
final iconColor = controller
|
||||
.drive(CurveTween(curve: Curves.fastOutSlowIn))
|
||||
.drive(ColorTween(
|
||||
begin: colorScheme.onBackground.withOpacity(0.54),
|
||||
@@ -235,10 +235,10 @@ class _DataTreeNodeState extends State<DataTreeNode>
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final ColorScheme colorScheme = Theme.of(context).colorScheme;
|
||||
final Color textColor = colorScheme.onBackground.withOpacity(0.87);
|
||||
final colorScheme = Theme.of(context).colorScheme;
|
||||
final textColor = colorScheme.onBackground.withOpacity(0.87);
|
||||
|
||||
final bool closed = !_isExpanded && _controller.isDismissed;
|
||||
final closed = !_isExpanded && _controller.isDismissed;
|
||||
|
||||
return widget.children.isEmpty
|
||||
// Leaf node.
|
||||
|
||||
@@ -107,8 +107,8 @@ class _SplitState extends State<Split> {
|
||||
|
||||
// Determine what fraction to give each child, including enough space to
|
||||
// display the divider.
|
||||
double firstSize = axisSize * firstFraction;
|
||||
double secondSize = axisSize * secondFraction;
|
||||
var firstSize = axisSize * firstFraction;
|
||||
var secondSize = axisSize * secondFraction;
|
||||
|
||||
// Clamp the sizes to be sure there is enough space for the dividers.
|
||||
firstSize = firstSize.clamp(halfDivider, axisSize - halfDivider) as double;
|
||||
|
||||
Reference in New Issue
Block a user