Use List.filled constructor instead of soon-to-be-deprecated List constructor (flutter/engine#22925)
This commit is contained in:
committed by
GitHub
parent
3dfa731239
commit
240e9648d3
@@ -89,7 +89,8 @@ class Square4x4Image {
|
||||
|
||||
static List<int> get bytes {
|
||||
const int bytesPerChannel = 4;
|
||||
final List<int> result = List<int>(_kWidth * _kWidth * bytesPerChannel);
|
||||
final List<int> result = List<int>.filled(
|
||||
_kWidth * _kWidth * bytesPerChannel, 0);
|
||||
|
||||
void fillWithColor(Color color, int min, int max) {
|
||||
for (int i = min; i < max; i++) {
|
||||
|
||||
Reference in New Issue
Block a user