fyne-io / fyne

Cross platform GUI toolkit in Go inspired by Material Design
https://fyne.io/
Other
25.35k stars 1.4k forks source link

Backspace and Delete key Do not Fire OnChanged Event #4117

Closed heejit closed 1 year ago

heejit commented 1 year ago

Checklist

Describe the bug

Entry widget do not fire Onchanged event on Delete and Backspace Key.

How to reproduce

Attached code

Screenshots

No response

Example code

package main

import (
    "fmt"

    "fyne.io/fyne/v2/app"
    "fyne.io/fyne/v2/widget"
)

func main() {
    fyneApp := app.NewWithID("com.xyz")
    mainWin := fyneApp.NewWindow("Bug Report")
    mainWin.SetMaster()
    mainWin.Show()

    w := widget.NewEntry()
    w.SetPlaceHolder("On Backspace and Delete Key OnChanged event do not fire")
    w.OnChanged = func(v string) {
        fmt.Println("On Changed called")
    }

    mainWin.SetContent(w)

    fyneApp.Run()
}

Fyne version

fyne.io/fyne/v2 v2.3.6-0.20230801132204-0b324c4306a0

Go compiler version

1.20

Operating system and version

Linux

Additional Information

No response

andydotxyz commented 1 year ago

Resolved on develop

heejit commented 1 year ago

I tested it is okay now.