update downloadto

This commit is contained in:
源文雨
2022-12-26 13:27:28 +08:00
parent fa8428ae8b
commit d0610b152f
8 changed files with 27 additions and 17 deletions

View File

@@ -12,6 +12,7 @@ import (
"github.com/Coloured-glaze/gg"
"github.com/FloatTech/floatbox/file"
"github.com/FloatTech/floatbox/img/writer"
"github.com/FloatTech/floatbox/process"
ctrl "github.com/FloatTech/zbpctrl"
"github.com/FloatTech/zbputils/control"
"github.com/FloatTech/zbputils/ctxext"
@@ -305,5 +306,6 @@ func initPic(picFile string) error {
if file.IsExist(picFile) {
return nil
}
return file.DownloadTo(backgroundURL, picFile, true)
defer process.SleepAbout1sTo2s()
return file.DownloadTo(backgroundURL, picFile)
}