gui/pkg/window/register.go
Virgil d3443d4be9
Some checks are pending
Security Scan / security (push) Waiting to run
Test / test (push) Waiting to run
chore(gui): add AX usage examples
2026-04-02 20:31:56 +00:00

16 lines
529 B
Go

package window
import "forge.lthn.ai/core/go/pkg/core"
// Register creates a factory closure that captures the Platform adapter.
// The returned function has the signature WithService requires: func(*Core) (any, error).
// Use: core.WithService(window.Register(platform))
func Register(p Platform) func(*core.Core) (any, error) {
return func(c *core.Core) (any, error) {
return &Service{
ServiceRuntime: core.NewServiceRuntime[Options](c, Options{}),
platform: p,
manager: NewManager(p),
}, nil
}
}