Fix object code

This commit is contained in:
2024-09-12 02:34:28 -04:00
parent dca3880a87
commit c2245ec304
7 changed files with 31 additions and 26 deletions

View File

@@ -40,7 +40,7 @@ func newMenu (parent tomo.Window, bounds image.Rectangle, items ...tomo.Object)
menu := &Menu { }
menu.bounds = bounds
menu.parent = parent
window, err := menu.parent.NewMenu(menu.bounds)
window, err := menu.parent.NewChild(tomo.WindowKindMenu, menu.bounds)
if err != nil { return nil, err }
menu.Window = window
@@ -75,7 +75,7 @@ func (this *Menu) TearOff () {
if this.parent == nil { return }
this.torn = true
window, err := this.parent.NewChild(this.bounds)
window, err := this.parent.NewChild(tomo.WindowKindToolbar, this.bounds)
window.SetIcon(tomo.IconListChoose)
if err != nil { return }