Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
While working on #5 / #10 i noticed focus was getting lost after the window was hidden then reshown (
set_visible(false)
). When I checked out master again the bug did not produce, indicating it was something on my branch. I created this PR/branch to minimize the changes to create the issue - which appears to just be bumping wry/tao version.Effectively, it looks like: tauri-apps/wry#184
Reproducing
cargo run
(You'll need yarn to get the resources to build, sorry 😬 )cmd+space
), notice you have focusset_focus(false)
in the event loop)cmd+space
) again, but notice focus isn't on it anymore.WRY Version
I was already on a relatively new version, and the diff shows that: https://github.com/tauri-apps/wry/compare/81f3218d9ac55a987b050f574774afcaa0b5c2f7..761b2b59fe0434b3458d99ed599394af0e1e3962
The only meaningful change was in WebContext, which doesn't really sound like a source of the problem
TAO Version
Conversely, Wry is currently pinned to
0.2.6
of TAO; whereas my PR had to pin to a newer version to get the keyboard/system tray improvements. When we compare that diff, it's much larger: https://github.com/tauri-apps/tao/compare/afd1316a7e0289ec34fb49f12ccfb5e3c1387b7b..d1065e3d9e4f0f48b366ce9736a57b5866c003dbWhat stands out: there were focus changes which appear to have added this logic