ppforge/internal/ui/fieldadd.go

17 lines
277 B
Go
Raw Normal View History

package ui
2022-11-23 20:33:07 +01:00
import (
"fyne.io/fyne/v2/widget"
)
var fieldAdder *widget.Button
func GetAdder() *widget.Button {
if fieldAdder == nil {
fieldAdder = widget.NewButton("Add Field", func() {
2022-11-24 21:49:10 +01:00
protocolEditor.AddFieldCreator(CreateFieldCreator())
2022-11-23 20:33:07 +01:00
})
}
return fieldAdder
}