-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathprogress.dart
47 lines (39 loc) · 1.2 KB
/
progress.dart
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'platform.dart';
class PActivityIndicator extends PlatformAdaptingWidget {
final Animation<Color> androidValueColor;
final double androidStrokeWidth;
final bool iosAnimating;
final double iosRadius;
final String semanticsLabel;
final String semanticsValue;
PActivityIndicator(
{Key key,
this.androidValueColor,
this.androidStrokeWidth,
this.iosAnimating = true,
this.iosRadius = 10.0,
/// hope that Flutter iOS will support this in the future for ADA
this.semanticsLabel,
this.semanticsValue,
TargetPlatform renderPlatform})
: super(key: key, renderPlatform: renderPlatform);
@override
get renderMaterial => (BuildContext context) {
return CircularProgressIndicator(
key: key,
valueColor: androidValueColor,
semanticsLabel: semanticsLabel,
semanticsValue: semanticsValue,
);
};
@override
get renderCupertino => (BuildContext context) {
return CupertinoActivityIndicator(
key: key,
animating: iosAnimating,
radius: iosRadius,
);
};
}