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

app: [js] fix tabbing #116

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

app: [js] fix tabbing #116

wants to merge 5 commits into from

Conversation

inkeliz
Copy link
Contributor

@inkeliz inkeliz commented Jul 4, 2023

No description provided.

egonelbre and others added 5 commits June 27, 2023 10:41
                 │   sec/op    │   sec/op     vs base               │
SplitCubic/4-10    37.36n ± 0%   36.16n ± 0%  -3.21% (p=0.000 n=10)
SplitCubic/8-10    74.53n ± 0%   72.21n ± 0%  -3.12% (p=0.000 n=10)
SplitCubic/16-10   149.3n ± 1%   144.5n ± 0%  -3.22% (p=0.000 n=10)
SplitCubic/33-10   340.1n ± 0%   334.4n ± 0%  -1.65% (p=0.000 n=10)

Signed-off-by: Egon Elbre <[email protected]>
Signed-off-by: inkeliz <[email protected]>
Comment on lines +322 to +324
if e.focused {
key.SoftKeyboardOp{Show: true}.Add(gtx.Ops)
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you expand the commit message to say what issue this fixes? Is there a TODO number?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without that change TAB on browser will switch the focus to another input (which is expected!), but the focus is removed, in the next frame.

Currently, on JS, Gio focus/blur one input based on SoftKeyboardOp, even on desktop.

Previously, SoftKeyboardOp is requested using requestFocus, which happens only after clicking into the input. However, when the focus shifts to another input without clicking (which is the tabbing case): it don't triggers requestFocus, then it doesn't use SoftKeyboardOp.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This losing of focus after TAB sounds like a browser-only issue, correct? If so, can it be fixed in os_js.go so Editor doesn't need to know?

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.

3 participants