@@ -3,7 +3,6 @@ package rendercard
33import (
44 "image"
55 "image/color"
6- "math/rand"
76 "sync"
87
98 "github.com/FloatTech/floatbox/math"
@@ -143,17 +142,17 @@ func renderinfocards(torussd, glowsd []byte, plugininfos []*PluginInfo) (img ima
143142 fade .AddColorStop (0.7 , color.NRGBA {204 , 51 , 51 , 63 })
144143 fade .AddColorStop (0.6 , color.NRGBA {204 , 51 , 51 , 0 })
145144 fade .AddColorStop (0 , color.NRGBA {204 , 51 , 51 , 0 })
146- statusimage := drawEnableOrDisableImage (false )
145+ statusimage := drawEnableOrDisableImage (plugininfos [ i ]. Status )
147146
148- if plugininfos [i ].Status && rand . Intn ( 2 ) == 0 {
147+ if plugininfos [i ].Status {
149148 canvas .SetRGBA255 (136 , 178 , 0 , 255 )
150149 fade = gg .NewLinearGradient (beginw + 10 , 0 , beginw + cardw - 10 , 0 )
151150 fade .AddColorStop (1 , color.NRGBA {136 , 178 , 0 , 255 })
152151 fade .AddColorStop (0.8 , color.NRGBA {136 , 178 , 0 , 191 })
153152 fade .AddColorStop (0.7 , color.NRGBA {136 , 178 , 0 , 63 })
154153 fade .AddColorStop (0.6 , color.NRGBA {136 , 178 , 0 , 0 })
155154 fade .AddColorStop (0 , color.NRGBA {136 , 178 , 0 , 0 })
156- statusimage = drawEnableOrDisableImage (true )
155+ statusimage = drawEnableOrDisableImage (plugininfos [ i ]. Status )
157156 }
158157
159158 canvas .DrawRoundedRectangle (beginw + 10 , beginh , cardw - 10 , cardh , 16 )
0 commit comments