package ui import ( "fyne.io/fyne/v2/widget" "gitea.mmo.to/ppForge/ppforge/protocolctl" ) func GetAdder(pEd *ProtocolEditor) *widget.Button { fieldAdder := widget.NewButton("Add Field", func() { f := protocolctl.NewEmptyField() index := protocolctl.AppendField(pEd.Reference, f) pEd.AddFieldCreator(CreateFieldEditor(pEd, index, f)) }) return fieldAdder }