Skip to content

Calling Entry.SetText and then Entry.Bind immediately will ignore the bound value #4235

Closed
@andydotxyz

Description

Checklist

  • I have searched the issue tracker for open issues that relate to the same problem, before opening a new one.
  • This issue only relates to a single bug. I will open new issues for any other problems.

Describe the bug

Due to recent "debounce" delay code the SetText is taken as user input, but if done before a bind this is not correct.

How to reproduce

  • Create an Entry
  • Set the text
  • Bind
  • See that the bound value is not shown

Screenshots

No response

Example code

s := binding.NewString()
s.Set("replace")
e := widget.NewEntry()
e.SetText("Thing")
e.Bind(s)

Fyne version

2.4.0

Go compiler version

1.21.1

Operating system and version

Darwin

Additional Information

No response

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions