Sub Globals
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
Dim p1,p2,p3,p4,p5,p6 As MaterialCircleProgress
Dim MaterialColors(19) As Map
End Sub
Sub Activity_Create(FirstTime As Boolean)
'Do not forget to load the layout file created with the visual designer. For example:
'Activity.LoadLayout("Layout1")
initMaterialColors
p1.Initialize("")
Activity.AddView(p1,0,0,150dip,150dip)
p1.Colors = Array As Int(Colors.Red,Colors.Blue,Colors.Green,Colors.Yellow)
p1.CircleBackgroundEnabled = False
p1.ProgressStrokeWidth = 5dip
p1.ShowArrow = True
p1.ArrowHeight = 15dip
p1.ArrowWidth = 25dip
p2.Initialize("")
Activity.AddView(p2,200dip,0,150dip,150dip)
Dim paletteIndex As Int = 0
p2.Colors = Array As Int(MaterialColors(paletteIndex).Get(50),MaterialColors(paletteIndex).Get(100),MaterialColors(paletteIndex).Get(200),MaterialColors(paletteIndex).Get(300),MaterialColors(paletteIndex).Get(400),MaterialColors(paletteIndex).Get(500),MaterialColors(paletteIndex).Get(600),MaterialColors(paletteIndex).Get(700),MaterialColors(paletteIndex).Get(800),MaterialColors(paletteIndex).Get(900))
p2.CircleBackgroundEnabled = False
p2.ProgressStrokeWidth = 20dip
p2.ShowArrow = False
p3.Initialize("")
Activity.AddView(p3,0,180dip,150dip,150dip)
p3.Colors = Array As Int(Colors.Red,Colors.Blue,Colors.Green,Colors.Yellow)
p3.CircleBackgroundEnabled = True
p3.ProgressStrokeWidth = 10dip
p3.ShowArrow = True
p3.ArrowHeight = 15dip
p3.ArrowWidth = 25dip
p4.Initialize("")
Activity.AddView(p4,200dip,180dip,150dip,150dip)
p4.Colors = Array As Int(Colors.Red,Colors.Blue,Colors.Green,Colors.Yellow)
p4.CircleBackgroundEnabled = True
p4.ProgressStrokeWidth = 10dip
p4.ShowArrow = False
p4.ArrowHeight = 15dip
p4.ArrowWidth = 25dip
p5.Initialize("")
Activity.AddView(p5,0,360dip,100dip,100dip)
p5.Colors = Array As Int(Colors.Red,Colors.Blue,Colors.Green,Colors.Yellow)
p5.CircleBackgroundEnabled = True
p5.ProgressStrokeWidth = 10dip
p5.ShowArrow = True
p5.ArrowHeight = 15dip
p5.ArrowWidth = 25dip
p6.Initialize("")
Activity.AddView(p6,200dip,360dip,50dip,50dip)
p6.Colors = Array As Int(Colors.Red,Colors.Blue,Colors.Green,Colors.Yellow)
p6.CircleBackgroundEnabled = True
p6.ProgressStrokeWidth = 5dip
p6.InnerRadius = 15dip
p6.ShowArrow = False
p6.ArrowHeight = 15dip
p6.ArrowWidth = 25dip
End Sub