Overlays: review r1 fixes

This commit is contained in:
ZacharyZhang-NY committed 2026-10-05 12:59:33 -04:00
1 parent a27727bc71
commit e631f88cc0
41 files changed
+770 -278

No files matched your search

+1 -5
View File
@@ -17,11 +17,7 @@ type contextMenuState struct {
x, y float32
}
// ContextMenu gives target an in-window menu that build fills. A secondary
// click opens it at the pointer; the menu key or Shift+F10, while the focus
// is in target, opens it below target. It flips to stay in the window, and
// the focus returns on close. target must be a container: the menu adds an
// anchor child to it, and takes its HandleInput. It returns target.
// ContextMenu gives the container target an in-window menu at the pointer or below the focus.
func ContextMenu(c *ui.Context, target *ui.Element, opts ContextMenuOptions, build func(m *PopupMenu)) *ui.Element {
if target == nil {
panic("mujica: ContextMenu needs a target")