packages upgrade, reverted svg colorFilter move (undeprecated in flutter_svg 0.19.2)
This commit is contained in:
parent
78f5abc39c
commit
893e3b5fa0
5 changed files with 14 additions and 12 deletions
|
@ -1,6 +1,5 @@
|
|||
import 'package:aves/utils/geo_utils.dart';
|
||||
import 'package:latlong/latlong.dart';
|
||||
import 'package:tuple/tuple.dart';
|
||||
|
||||
enum CoordinateFormat { dms, decimal }
|
||||
|
||||
|
|
|
@ -32,10 +32,10 @@ class ThumbnailVectorImage extends StatelessWidget {
|
|||
UriPicture(
|
||||
uri: entry.uri,
|
||||
mimeType: entry.mimeType,
|
||||
colorFilter: colorFilter,
|
||||
),
|
||||
width: extent,
|
||||
height: extent,
|
||||
colorFilter: colorFilter,
|
||||
);
|
||||
},
|
||||
),
|
||||
|
|
|
@ -8,10 +8,13 @@ class UriPicture extends PictureProvider<UriPicture> {
|
|||
const UriPicture({
|
||||
@required this.uri,
|
||||
@required this.mimeType,
|
||||
this.colorFilter,
|
||||
}) : assert(uri != null);
|
||||
|
||||
final String uri, mimeType;
|
||||
|
||||
final ColorFilter colorFilter;
|
||||
|
||||
@override
|
||||
Future<UriPicture> obtainKey(PictureConfiguration configuration) {
|
||||
return SynchronousFuture<UriPicture>(this);
|
||||
|
@ -34,22 +37,22 @@ class UriPicture extends PictureProvider<UriPicture> {
|
|||
|
||||
final decoder = SvgPicture.svgByteDecoder;
|
||||
if (onError != null) {
|
||||
final future = decoder(data, null, key.toString());
|
||||
final future = decoder(data, colorFilter, key.toString());
|
||||
unawaited(future.catchError(onError));
|
||||
return future;
|
||||
}
|
||||
return decoder(data, null, key.toString());
|
||||
return decoder(data, colorFilter, key.toString());
|
||||
}
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
if (other.runtimeType != runtimeType) return false;
|
||||
return other is UriPicture && other.uri == uri;
|
||||
return other is UriPicture && other.uri == uri && other.colorFilter == colorFilter;
|
||||
}
|
||||
|
||||
@override
|
||||
int get hashCode => uri.hashCode;
|
||||
int get hashCode => hashValues(uri, colorFilter);
|
||||
|
||||
@override
|
||||
String toString() => '${objectRuntimeType(this, 'UriPicture')}(uri=$uri, mimeType=$mimeType)';
|
||||
String toString() => '${objectRuntimeType(this, 'UriPicture')}(uri=$uri, mimeType=$mimeType, colorFilter=$colorFilter)';
|
||||
}
|
||||
|
|
|
@ -203,9 +203,9 @@ class _ImageViewState extends State<ImageView> {
|
|||
UriPicture(
|
||||
uri: entry.uri,
|
||||
mimeType: entry.mimeType,
|
||||
colorFilter: colorFilter,
|
||||
),
|
||||
placeholderBuilder: (context) => _loadingBuilder(context, fastThumbnailProvider),
|
||||
colorFilter: colorFilter,
|
||||
),
|
||||
backgroundDecoration: backgroundDecoration,
|
||||
controller: _photoViewController,
|
||||
|
|
|
@ -21,7 +21,7 @@ packages:
|
|||
name: ansicolor
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.0.5"
|
||||
version: "1.1.1"
|
||||
archive:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -324,7 +324,7 @@ packages:
|
|||
name: flutter_markdown
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.5.0"
|
||||
version: "0.5.1"
|
||||
flutter_native_timezone:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
|
@ -535,7 +535,7 @@ packages:
|
|||
name: node_interop
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.2.0"
|
||||
version: "1.2.1"
|
||||
node_io:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -647,7 +647,7 @@ packages:
|
|||
name: pdf
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.11.2"
|
||||
version: "1.12.0"
|
||||
pedantic:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
|
|
Loading…
Reference in a new issue