mirror of https://github.com/ImVexed/muon.git
callback fix
This commit is contained in:
parent
fa29078bc6
commit
79fe390b3f
|
@ -3,6 +3,6 @@ module cra-go
|
||||||
go 1.13
|
go 1.13
|
||||||
|
|
||||||
require (
|
require (
|
||||||
github.com/ImVexed/muon v0.0.0-20191007190516-f77a06ba12f4
|
github.com/ImVexed/muon v0.0.0-20191008002922-fa29078bc6e0
|
||||||
golang.org/x/net v0.0.0-20190930134127-c5a3c61f89f3
|
golang.org/x/net v0.0.0-20190930134127-c5a3c61f89f3
|
||||||
)
|
)
|
||||||
|
|
|
@ -12,10 +12,11 @@ func main() {
|
||||||
fileHandler := http.FileServer(webfiles.HTTP)
|
fileHandler := http.FileServer(webfiles.HTTP)
|
||||||
|
|
||||||
cfg := &muon.Config{
|
cfg := &muon.Config{
|
||||||
Title: "Hello, World!",
|
Title: "Hello, World!",
|
||||||
Height: 500,
|
Height: 500,
|
||||||
Width: 500,
|
Width: 500,
|
||||||
Hint: 2 | 4,
|
Tilted: true,
|
||||||
|
Resizeable: true,
|
||||||
}
|
}
|
||||||
|
|
||||||
m := muon.New(cfg, fileHandler)
|
m := muon.New(cfg, fileHandler)
|
||||||
|
|
2
muon.go
2
muon.go
|
@ -78,7 +78,7 @@ func New(cfg *Config, handler http.Handler) *Window {
|
||||||
|
|
||||||
w.ov = UlCreateOverlay(w.wnd, w.cfg.Height, w.cfg.Width, w.cfg.X, w.cfg.Y)
|
w.ov = UlCreateOverlay(w.wnd, w.cfg.Height, w.cfg.Width, w.cfg.X, w.cfg.Y)
|
||||||
|
|
||||||
UlWindowSetResizeCallback(w.wnd, resizeCallback(w.ov), unsafe.Pointer(&w.ov))
|
UlWindowSetResizeCallback(w.wnd, resizeCallback(w.ov), nil)
|
||||||
|
|
||||||
w.view = UlOverlayGetView(w.ov)
|
w.view = UlOverlayGetView(w.ov)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue