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

Fix Back button in Android TV Remote Control app #13049

Merged
merged 4 commits into from
Nov 17, 2017

Conversation

garbear
Copy link
Member

@garbear garbear commented Nov 14, 2017

The Back button shows up as a joystick button, which is mapped to the B button in xbmc/peripheral.joystick#129 (and backported to Krypton).

This PR makes the B button behave like the Backspace button on a keyboard, which is how the button is interpreted when peripheral.joystick is disabled. Now, the Back button should work the same whether it's operating as a joystick or keyboard.

This required two steps: changing joystick.xml to match keyboard.xml and fixing a joystick bug. The bug caused the FullscreenVideo window to close immediately upon reopening from the Home screen.

Motivation and Context

Reported here: https://forum.kodi.tv/showthread.php?tid=308480&pid=2667452#pid2667452

How Has This Been Tested?

  • Tested on Shield TV with Android TV Remote Control app
  • Tested on Linux with Xbox 360 controller

Screenshots (if appropriate):

Android TV Remote Control:
android tv remote control

Types of change

  • Bug fix (non-breaking change which fixes an issue)
  • Improvement (non-breaking change which improves existing functionality)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

@garbear garbear added Type: Fix non-breaking change which fixes an issue Component: Input v18 Leia labels Nov 15, 2017
@garbear garbear added this to the L 18.0-alpha1 milestone Nov 15, 2017
@garbear
Copy link
Member Author

garbear commented Nov 16, 2017

jenkins build this please

Previously, pressing B would immediately stop the video.

After changing this to match the Backspace key behavior, pressing B will
toggle fullscreen and holding B will stop.
This makes the B button mirror the behavior of the Backspace key.
@garbear garbear merged commit a2323e3 into xbmc:master Nov 17, 2017
@garbear garbear deleted the joystick-back branch November 17, 2017 17:53
@bb10
Copy link
Contributor

bb10 commented Nov 26, 2018

That would be a great improvement, yes.

@garbear
Copy link
Member Author

garbear commented Nov 26, 2018

@bb10 I raised your idea on the forum thread: https://forum.kodi.tv/showthread.php?tid=308480&pid=2795177#pid2795177

Just to see what others think. I'm for switching the two like you proposed.

@bb10
Copy link
Contributor

bb10 commented Jan 16, 2019

Any update on this? Would be a shame if this made it into the final v18 release.

@garbear
Copy link
Member Author

garbear commented Jan 16, 2019

Can you open a PR with the ideas suggested in the thread? I can't until this weekend, so to hit v18 it should be opened today.

@bb10
Copy link
Contributor

bb10 commented Jan 16, 2019

I hope I did this right, it's my first PR.
#15267 is a conservative change, just reversing the B button actions.
#15268 is a more radical change, which has a bunch of back button additions and changes and also reverses the B button actions like the former.

I did not feel comfortable changing the keyboard.xml atm. I guess we could just change it and see if anyone complains and revert it in a point release if anyone does?

The problem is that CiNcH somehow expects B and backspace to behave the same, but they never have and any changes to them will be breaking for any keyboard and joystick users.

Let me know what you think. 😃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Input Type: Fix non-breaking change which fixes an issue v18 Leia
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants