Documentation
¶
Overview ¶
Package devfeat holds the core's development features: window placement across `tan dev` restarts (windowstate.go) and the whole-app automation channel (automation.go, docs/automation.md). They are only built with -tags tango_dev; production builds, the default, get the empty implementations of release.go.
Package tango calls AttachWindowState and AttachAutomation for every new App. This package cannot import package tango (tango imports it): it uses the App's exported methods through the App interface and reaches core internals through the hooks of package internal/corehook, which package tango sets.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AttachAutomation ¶
func AttachAutomation(App)
AttachAutomation does nothing in release builds: the automation control channel (automation.go, docs/automation.md) is a development feature and TANGO_AUTOMATION is ignored.
func AttachWindowState ¶
func AttachWindowState(App)
AttachWindowState does nothing in release builds: restoring window placement across restarts is a `tan dev` feature (windowstate.go).
Types ¶
type App ¶
type App interface {
OnReady(fn func())
OnLifecycle(fn func(platform.LifecycleEvent))
Backend() platform.Backend
Quit()
}
App is the part of *tango.App's exported API the development features use. The value passed to the Attach functions must be a *tango.App: the corehook hooks type-assert it.