-
Notifications
You must be signed in to change notification settings - Fork 1
/
main.go
36 lines (34 loc) · 978 Bytes
/
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
package main
import (
"github.com/lexisother/frenyard"
"github.com/lexisother/frenyard/design"
"github.com/lexisother/frenyard/framework"
"github.com/replugged-org/installer/middle"
"github.com/replugged-org/installer/src"
)
func main() {
frenyard.TargetFrameTime = 0.016
slideContainer := framework.NewUISlideTransitionContainerPtr(nil)
slideContainer.FyEResize(design.SizeWindowInit)
wnd, err := framework.CreateBoundWindow("Replugged Installer", true, design.ThemeBackground, slideContainer)
if err != nil {
panic(err)
}
design.Setup(frenyard.InferScale(wnd))
wnd.SetSize(design.SizeWindow)
app := &src.UpApplication{
Config: middle.ReadConfig(),
MainContainer: slideContainer,
Window: wnd,
UpQueued: make(chan func(), 16),
TeleportSettings: framework.SlideTransition{},
}
app.ShowPreface()
frenyard.GlobalBackend.Run(func(frametime float64) {
select {
case fn := <-app.UpQueued:
fn()
default:
}
})
}