-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.go
60 lines (47 loc) · 1.17 KB
/
main.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
package main
import (
"embed"
_ "embed"
_ "image/png"
"log"
"changeme/internal/texture/service/importer"
"github.com/wailsapp/wails/v3/pkg/application"
)
//go:embed frontend/dist
var assets embed.FS
//go:embed icon.png
var logo []byte
func main() {
app := application.New(application.Options{
Name: "Iris",
Icon: logo,
Description: "RedKit texture map importer.",
Services: []application.Service{
application.NewService(&importer.Importer{}),
},
Assets: application.AssetOptions{
Handler: application.AssetFileServerFS(assets),
},
Mac: application.MacOptions{
ApplicationShouldTerminateAfterLastWindowClosed: true,
},
})
_ = app.NewWebviewWindowWithOptions(application.WebviewWindowOptions{
Title: "Iris",
Mac: application.MacWindow{
InvisibleTitleBarHeight: 50,
Backdrop: application.MacBackdropTranslucent,
TitleBar: application.MacTitleBarHiddenInset,
},
Windows: application.WindowsWindow{},
MinWidth: 1430,
MinHeight: 890,
DisableResize: true,
BackgroundColour: application.NewRGB(255, 255, 255),
URL: "/",
})
err := app.Run()
if err != nil {
log.Fatal(err)
}
}