-
func vstart() {
b := gi.NewAppBody("vstart")
b.Style(func(s *styles.Style) {
s.Direction = styles.Row
s.Display = styles.Grid
//s.Overflow.Set(styles.OverflowAuto)
})
for i := 0; i < 300; i++ {
gi.NewButton(b).SetText(fmt.Sprint(i)).AddContextMenu(func(m *gi.Scene) {
gi.NewButton(m).SetText("run")
gi.NewButton(m).SetText("open dir")
})
}
b.NewWindow().Run().Wait()
} |
Beta Was this translation helpful? Give feedback.
Answered by
kkoreilly
Jan 18, 2024
Replies: 3 comments 3 replies
-
Interesting -- the Button has its own Menu field, but probably we should just use the standard ContextMenu functionality. |
Beta Was this translation helpful? Give feedback.
0 replies
-
It should be fixed now (in 20144e5). Thanks for reporting this! |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
ddkwork
-
Kai fix doesn't actually use the ContextMenus, right? What about changing button to use that instead of a separate Menu field? |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It should be fixed now (in 20144e5). Thanks for reporting this!