-
-
Notifications
You must be signed in to change notification settings - Fork 226
#1276 refactor: fallback to scanCode when keyCode unknown #1564
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
#1276 refactor: fallback to scanCode when keyCode unknown #1564
Conversation
|
Thanks! I invalidated all the strings because in version 3.0 I changed so much stuff that the translations were down to 60% or lower and will need to wait before they are complete again. A lot just changed on develop so I hope the conflicts weren't an issue. |
9c19a80 to
cb863bb
Compare
I got lucky, and had no major issues with the rebase. All of these force-pushes are from my own mistakes, like not running unit tests / code style locally / some nitpicks etc. BTW I'll not have steady access to my "Android Studio capable" PC after Saturday for the next ~2 weeks, so I won't be able to ideate / work further on the PR after this, or maybe I will be able to, but with a time delay ✌️ |
7a4cef2 to
2bfc15b
Compare
sds100
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for github actions tweaks and the documentation fixes as well :)
app/src/main/java/io/github/sds100/keymapper/system/inputevents/InputEventUtils.kt
Outdated
Show resolved
Hide resolved
.../main/java/io/github/sds100/keymapper/mappings/keymaps/trigger/BaseConfigTriggerViewModel.kt
Show resolved
Hide resolved
5a1d6ce to
4428ae6
Compare
refactor: don't offset negative scanCode
4428ae6 to
30f5d8b
Compare
|
Is there something else that I need to do? Is a unit test a requirement for this PR to be merged? |
|
Thanks for the merge ❤️ |
|
So I've been setting up my key maps for the usage on the trip during the next 2 weeks. Sorry for noticing it after the merge @sds100, should I make another PR or will you make a fast fixup commit? If |
|
I'll do it quickly :) |
|
Can you check the latest commit on develop |
|
Yup, fetched the changes and the triggers stopped working again, due to scan code change, so I had to update the triggers. Thanks for fast commit revert ✌️ 🥳
|
Hi 👋 ,
Before the rebase onto develop-HEAD, I did check on my develop branch that the CI passed:
The current develop-HEAD doesn't pass CI, so I haven't run it on the fork, but I built the app locally and side loaded the debug app onto my phone, and all relevant functionality is preserved.
I also wanted to add a Polish resource string, but the current Crowdin setup appears to be somewhat broken as it invalidated every translation.
KeyMapper/app/src/main/res/values-pl/strings.xml
Line 385 in a66c39b
Thanks to this I've noticed that it's likely a requirement to add translations via Crowdin, as it's a one-way pipeline for translations into the repo, and it doesn't go the other way, so I can't update translations via PR.
So just to be sure I need to create a Crowdin account to join in the translation involvement? Then again 90% was finished before, so I'm not sure if I should butt in with my unsolicited advice, even though I've seen some "controversial" translations, but also nothing directly incorrect 😅
I use English on my phone, so I didn't notice the Polish translations at first, but when I switched I noticed some missing strings.
Then after looking into the code it turned out they're hardcoded:
KeyMapper/app/src/main/java/io/github/sds100/keymapper/system/inputevents/InputEventUtils.kt
Lines 699 to 703 in 7d7c134
As for the Shizuku stuff mentioned before in the Issue, I've installed it, and thanks to this the accessibility service auto restarts after app reinstall 👍. Then I looked into intercepting the input events from Shizuku and came up short, especially since it would have to be injected in the correct place to go well with the current keyCode pipeline or would have to replace most of it, and then you mentioned adding custom getevent handlers and other low level linux things, so this topic is likely beyond my skill set / time investment capabilities at the moment. Therefore, I hope this PR will do ✌️
I can move the CI/build related stuff to another PR if you want, but I don't think it's necessary, so I kept it here.
Or maybe I should squash the 2 Issue related commits into one and keep only 1 commit + the CI/build commits?
Fixes #1276
I haven't checked the other #1277 Issue, as responding to keys while screen is off requires root access?