-
-
Notifications
You must be signed in to change notification settings - Fork 77
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
Add Gyroscope, rewrite GestureDetectListener #25
base: master
Are you sure you want to change the base?
Conversation
Does your version work on Android 12? I can't even get the app to open. |
Still crashes. java.lang.SecurityException: Need BLUETOOTH PRIVILEGED permission: neither user 11486 nor current process has android.permission BLUETOOTH_PRIVILEGED . |
Would you mind providing me the whole stack trace? I am not able to reproduce the crash by myself, because I don't own a physical android 12 device (the app does launch on the emulator (API 31), which unfortunately does not support Bluetooth). |
It doesn't crash anymore and I can verify that basic functionality works. What are the buttons at the top supposed to do? The Bluetooth icon is also a button, but appears to do nothing. Long pressing it just gives me a toast message with the current Bluetooth status. Maybe it should open Bluetooth settings? Just an idea. It would also be a good idea to remove unnecessary permissions, especially location: https://developer.android.com/guide/topics/connectivity/bluetooth/permissions I will make a pull request (against your fork) with permission fixes now. |
Remove unnecessary permissions
Change which permissions are checked at launch to reflect permissions removed when targeting Android 12
Permissions fix
# Conflicts: # app/src/main/java/com/github/roarappstudio/btkontroller/SplashScreen.kt
It should work on Android 10 now. I hope the other changes have not broken the Android 12 compatibility again. I don't exactly know what P/N does either. A dedicated menu for all Bluetooth related settings might actually not be a bad idea. (Currently the app will always ask for pairing when recovering from standby, and the disconnect button does not seem to work correctly. I will look into these issues later.) |
Latest build crashes. Here is the logcat: https://docs.google.com/document/d/1oYSM0V74Ny8cYr2K5MWmeJiO80uhOToJZirZ8Ks9FoU/edit?usp=sharing The interesting bit is: Shouldn't this be granted when the user accepts Nearby Devices as part of the Bluetooth scan check on the splash screen? |
You could try checking out commit 48f9d11 , which also asks for the connect permission. If that works I can add it back in. |
I cloned the repository and set it to that particular commit. It does not crash, but after accepting the Nearby Devices permission, it does not load the main activity either (stays on a blank screen). There are no errors in the logcat. |
# Conflicts: # app/src/main/java/com/github/roarappstudio/btkontroller/SplashScreen.kt
I can verify that the latest build works. According to the page on Google play, the P and N has to do with the optional hacker's keyboard app, to make it easier to press certain key combinations. I tried it and not only does it work as expected, but it's pretty great: As an aside, I think I prefer the original layout of the upper right menu bar, so I submitted a pull request. This should prevent you from accidentally changing the P/N mode when bringing up the keyboard. What is autopair even supposed to do? I see no difference with it on or off; I wonder if this is related to the Disconnect issue. |
Restore original menu order
Submitted pull request, see above |
Update select_device_activity_menu.xml
When using a software keyboard with navigation keys (e.g. hacker's keyboard), the menu in Kontroller gains focus and prevents the key press from being sent. Is there a way to prevent the items in select_device_activity_menu.xml |
I have modified the GestureDetectListener to behave in a, in my opinion, more natural way (Right click and scroll aren't triggered at the same time anymore, the mouse pointer does not jump around when scrolling, double left clicks are triggered without delay, so dragging is possible immediately, the scrolling issue persists though). Volume up and down now trigger left and right clicks.
I have removed some unused code (e.g. some comments, AbsoluteMouseReports ...) and I am not sure if I should add it back in?