prepare loader ui

This commit is contained in:
Ilia Denisov
2026-03-15 20:40:25 +02:00
parent 1ea03495f6
commit fbcf4cef99
8 changed files with 191 additions and 57 deletions
+7 -2
View File
@@ -5,6 +5,7 @@ import (
"errors"
"fmt"
"galaxy/client/loader"
"galaxy/connector/http"
"galaxy/storage/fs"
"os"
"os/signal"
@@ -29,12 +30,16 @@ func main() {
ctx, cancel := signal.NotifyContext(context.Background(), os.Interrupt)
defer cancel()
app := app.NewWithID("galaxy-client")
app := app.NewWithID("GalaxyPlus")
s, err := fs.NewFS(app.Storage().RootURI().Path())
if err != nil {
return
}
l, err := loader.NewLoader(ctx, s, nil, app)
c, err := http.NewHttpConnector(ctx, "http://127.0.0.1:8080")
if err != nil {
return
}
l, err := loader.NewLoader(s, c, app)
if err != nil {
return
}
+1 -7
View File
@@ -1,12 +1,10 @@
package main
import (
"context"
"errors"
"fmt"
"galaxy/client"
"os"
"os/signal"
"fyne.io/fyne/v2/app"
)
@@ -25,11 +23,7 @@ func main() {
}
}()
app := app.New()
ctx, cancel := signal.NotifyContext(context.Background(), os.Interrupt)
defer cancel()
c, err := client.NewClient(ctx, nil, nil, app)
c, err := client.NewClient(nil, nil, app)
if err != nil {
return
}