File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -50,9 +50,10 @@ abstract class TextDelegate {
50
50
/// 未支持的资源类型的字段
51
51
String unSupportedAssetType;
52
52
53
- /// This is used in video asset item in picker, in order to display the duration of the asset.
54
- /// 该字段用在选择器视频部件上,用于显示视频资源的时长。
55
- String videoIndicatorBuilder (Duration duration);
53
+ /// This is used in video asset item in picker, in order to display
54
+ /// the duration of the video or audio type of asset.
55
+ /// 该字段用在选择器视频或音频部件上,用于显示视频或音频资源的时长。
56
+ String durationIndicatorBuilder (Duration duration);
56
57
}
57
58
58
59
/// Default text delegate implements with Chinese.
@@ -98,7 +99,7 @@ class DefaultTextDelegate implements TextDelegate {
98
99
String unSupportedAssetType = '尚未支持的资源类型' ;
99
100
100
101
@override
101
- String videoIndicatorBuilder (Duration duration) {
102
+ String durationIndicatorBuilder (Duration duration) {
102
103
const String separator = ':' ;
103
104
final String minute = '${(duration .inMinutes ).toString ().padLeft (2 , '0' )}' ;
104
105
final String second =
Original file line number Diff line number Diff line change @@ -536,8 +536,8 @@ class AssetPicker extends StatelessWidget {
536
536
Padding (
537
537
padding: const EdgeInsets .only (left: 4.0 ),
538
538
child: Text (
539
- Constants .textDelegate
540
- . videoIndicatorBuilder ( Duration (seconds: asset.duration)),
539
+ Constants .textDelegate. durationIndicatorBuilder (
540
+ Duration (seconds: asset.duration)),
541
541
style: const TextStyle (fontSize: 16.0 ),
542
542
),
543
543
),
You can’t perform that action at this time.
0 commit comments