@@ -23,25 +23,25 @@ abstract class StreamColorSwatches {
23
23
24
24
StreamColorSwatch _computeForBaseColor (int base );
25
25
26
- /// Gives a [StreamColorSwatches] , lerped to [other ] at [t] .
26
+ /// Gives a [StreamColorSwatches] , lerped between [a] and [b ] at [t] .
27
27
///
28
- /// If [this ] and [other ] are [identical] , returns [this] .
28
+ /// If [a ] and [b ] are [identical] , returns [this] .
29
29
///
30
30
/// Else returns an instance whose [forBaseColor] will call
31
- /// [this .forBaseColor] and [other .forBaseColor]
31
+ /// [a .forBaseColor] and [b .forBaseColor]
32
32
/// and return [StreamColorSwatch.lerp] 's result on those.
33
33
/// This computation is cached on the instance
34
34
/// in order to save work building [t] 's animation frame when there are
35
35
/// multiple UI elements using the same [subscription.color] .
36
- StreamColorSwatches lerp (StreamColorSwatches other , double t) {
36
+ static StreamColorSwatches lerp (StreamColorSwatches a, StreamColorSwatches b , double t) {
37
37
// This short-circuit helps when [a] and [b]
38
38
// are both [StreamColorSwatches.light]
39
39
// or both [StreamColorSwatches.dark].
40
40
// Empirically, [lerp] is called even when the theme hasn't changed,
41
41
// so this is an important optimization.
42
- if (identical (this , other )) return this ;
42
+ if (identical (a, b )) return a ;
43
43
44
- return _StreamColorSwatchesLerped (this , other , t);
44
+ return _StreamColorSwatchesLerped (a, b , t);
45
45
}
46
46
}
47
47
0 commit comments