2024-09-04 01:20:12 +09:00
|
|
|
package state
|
|
|
|
|
2024-09-08 13:19:48 +09:00
|
|
|
var (
|
|
|
|
cleanupCandidate []string
|
|
|
|
enablements *Enablements
|
|
|
|
xcbActionComplete bool
|
|
|
|
)
|
|
|
|
|
2024-09-04 01:20:12 +09:00
|
|
|
func RegisterRevertPath(p string) {
|
|
|
|
cleanupCandidate = append(cleanupCandidate, p)
|
|
|
|
}
|
|
|
|
|
2024-09-08 02:24:01 +09:00
|
|
|
func RegisterEnablement(e Enablements) {
|
|
|
|
if enablements != nil {
|
|
|
|
panic("enablement state set twice")
|
|
|
|
}
|
|
|
|
enablements = &e
|
|
|
|
}
|
|
|
|
|
2024-09-04 01:20:12 +09:00
|
|
|
func XcbActionComplete() {
|
|
|
|
if xcbActionComplete {
|
|
|
|
Fatal("xcb inserted twice")
|
|
|
|
}
|
|
|
|
xcbActionComplete = true
|
|
|
|
}
|