Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bruig: remove newline added on <enter> and don't submit empty msgs #195

Merged
merged 1 commit into from Apr 14, 2023

Conversation

tiagoalvesdulce
Copy link
Contributor

@tiagoalvesdulce tiagoalvesdulce commented Apr 9, 2023

Closes #186

I came up with a simple workaround to fix the issue where I remove the newline added by the TextFIeld when is pressed.

I think in the future we should move the RawKeyboardListener onKey handler to the onKeyEvent property of the editLineFocusNode. I played with this a little but it would require lifting some state up the Widget tree or passing a function from child to parent (which sounds weird). Suggestions are welcome.

While doing this I noticed I could send empty messages so this PR also prevents that.

@tiagoalvesdulce tiagoalvesdulce changed the title fix: remove newline added on <enter> press and don't submit empty msgs bruig: remove newline added on <enter> and don't submit empty msgs Apr 9, 2023
@miki-totefu miki-totefu merged commit 3b5ea14 into companyzero:master Apr 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

GUI: Pressing <enter> should send only
3 participants