fix: Fixed issues
This commit is contained in:
@@ -737,10 +737,13 @@ class MessageInputState extends State<MessageInput> {
|
|||||||
Container(
|
Container(
|
||||||
color: Colors.black.withOpacity(0.5),
|
color: Colors.black.withOpacity(0.5),
|
||||||
child: Center(
|
child: Center(
|
||||||
child: Icon(
|
child: CircleAvatar(
|
||||||
StreamIcons.check_send,
|
maxRadius: 12.0,
|
||||||
color: Colors.white,
|
backgroundColor: Colors.white,
|
||||||
size: 24.0,
|
child: Icon(
|
||||||
|
StreamIcons.check,
|
||||||
|
color: Colors.black,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@@ -826,7 +829,7 @@ class MessageInputState extends State<MessageInput> {
|
|||||||
|
|
||||||
void _getAllMedia() async {
|
void _getAllMedia() async {
|
||||||
var allAlbums = await PhotoGallery.listAlbums(mediumType: MediumType.image);
|
var allAlbums = await PhotoGallery.listAlbums(mediumType: MediumType.image);
|
||||||
//var allVideoAlbums = await PhotoGallery.listAlbums(mediumType: MediumType.video);
|
var allVideoAlbums = await PhotoGallery.listAlbums(mediumType: MediumType.video);
|
||||||
List<Medium> resultList = [];
|
List<Medium> resultList = [];
|
||||||
List<List<dynamic>> resultThumbnailList = [];
|
List<List<dynamic>> resultThumbnailList = [];
|
||||||
|
|
||||||
@@ -835,12 +838,13 @@ class MessageInputState extends State<MessageInput> {
|
|||||||
resultList.addAll(data.items);
|
resultList.addAll(data.items);
|
||||||
}
|
}
|
||||||
|
|
||||||
// for (var album in allVideoAlbums) {
|
for (var album in allVideoAlbums) {
|
||||||
// var data = await album.listMedia();
|
var data = await album.listMedia();
|
||||||
// resultList.addAll(data.items);
|
resultList.addAll(data.items);
|
||||||
// }
|
}
|
||||||
|
|
||||||
resultList.sort((a, b) => a.modifiedDate.compareTo(b.modifiedDate));
|
resultList.sort((a, b) => a.modifiedDate.compareTo(b.modifiedDate));
|
||||||
|
resultList = resultList.toSet().toList();
|
||||||
|
|
||||||
for (var e in resultList) {
|
for (var e in resultList) {
|
||||||
resultThumbnailList.add(await PhotoGallery.getThumbnail(mediumId: e.id));
|
resultThumbnailList.add(await PhotoGallery.getThumbnail(mediumId: e.id));
|
||||||
|
|||||||
Reference in New Issue
Block a user