MCPcopy
hub / github.com/lxn/walk / SaveState

Method SaveState

window.go:1263–1279  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1261}
1262
1263func (wb *WindowBase) SaveState() (err error) {
1264 wb.ForEachDescendant(func(widget Widget) bool {
1265 if persistable, ok := widget.(Persistable); ok && persistable.Persistent() {
1266 if err = persistable.SaveState(); err != nil {
1267 return false
1268 }
1269 }
1270
1271 if _, ok := widget.(Container); ok {
1272 return false
1273 }
1274
1275 return true
1276 })
1277
1278 return
1279}
1280
1281// Form returns the Form of the Window.
1282func (wb *WindowBase) Form() Form {

Callers

nothing calls this directly

Calls 3

ForEachDescendantMethod · 0.95
PersistentMethod · 0.65
SaveStateMethod · 0.65

Tested by

no test coverage detected