Skip to content

Commit cf7e841

Browse files
author
sparkmemory
committed
update
1 parent 1ab6875 commit cf7e841

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

app.go

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import (
55
"github.com/wailsapp/wails/v2/pkg/runtime"
66
"go-stock/backend/data"
77
"go-stock/backend/logger"
8-
"time"
98
)
109

1110
// App struct
@@ -27,14 +26,14 @@ func (a *App) startup(ctx context.Context) {
2726
// domReady is called after front-end resources have been loaded
2827
func (a *App) domReady(ctx context.Context) {
2928
// Add your action here
30-
ticker := time.NewTicker(time.Second)
31-
defer ticker.Stop()
32-
//定时更新数据
33-
go func() {
34-
for range ticker.C {
35-
runtime.WindowSetTitle(ctx, "go-stock "+time.Now().Format("2006-01-02 15:04:05"))
36-
}
37-
}()
29+
//ticker := time.NewTicker(time.Second)
30+
//defer ticker.Stop()
31+
////定时更新数据
32+
//go func() {
33+
// for range ticker.C {
34+
// runtime.WindowSetTitle(ctx, "go-stock "+time.Now().Format("2006-01-02 15:04:05"))
35+
// }
36+
//}()
3837
}
3938

4039
// beforeClose is called when the application is about to quit,

0 commit comments

Comments
 (0)