Rockbox

Tasklist

FS#10887 - Change poweroff to only check that the power button is pressed

Attached to Project: Rockbox
Opened by MichaelGiacomelli (saratoga) - Saturday, 02 January 2010, 06:38 GMT
Last edited by MichaelGiacomelli (saratoga) - Saturday, 29 May 2010, 21:54 GMT
Task Type Patches
Category Operating System/Drivers
Status Closed
Assigned To No-one
Operating System All players
Severity Low
Priority Normal
Reported Version Release 3.4
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Presently if the power button is held, but another button is accidentally pressed before the power down begins, the device does not shut down.

This is moderately annoying to me on the e200, but extremely annoying on the Clip, since on the Clip is really tiny and the volume buttons take up the entire side opposite to the power button.

This patch changes the shutdown to ignore other button presses. So if you hold volume and power, you still get to shutdown.

I'm not sure if this is safe on various targets.
This task depends upon

Closed by  MichaelGiacomelli (saratoga)
Saturday, 29 May 2010, 21:54 GMT
Reason for closing:  Accepted
Additional comments about closing:  Accepted in 26397.
Comment by MichaelGiacomelli (saratoga) - Sunday, 03 January 2010, 01:58 GMT
Grepping through keymaps, these look like the ones that define BUTTON_POWER combos:

apps/keymaps/keymap-c100.c:63: { ACTION_WPS_ABSETB_NEXTDIR,BUTTON_POWER|BUTTON_RIGHT, BUTTON_POWER },
apps/keymaps/keymap-c100.c:64: { ACTION_WPS_ABSETA_PREVDIR,BUTTON_POWER|BUTTON_LEFT, BUTTON_POWER },
apps/keymaps/keymap-c100.c:65: { ACTION_WPS_ABRESET, BUTTON_POWER|BUTTON_UP, BUTTON_POWER },

apps/keymaps/keymap-h10.c:53: { ACTION_STD_CANCEL, BUTTON_POWER|BUTTON_RIGHT, BUTTON_NONE },
apps/keymaps/keymap-h10.c:77: { ACTION_WPS_ABSETB_NEXTDIR, BUTTON_POWER|BUTTON_FF, BUTTON_POWER },
apps/keymaps/keymap-h10.c:78: { ACTION_WPS_ABSETA_PREVDIR, BUTTON_POWER|BUTTON_REW, BUTTON_POWER },
apps/keymaps/keymap-h10.c:79: { ACTION_WPS_ABRESET, BUTTON_POWER|BUTTON_PLAY, BUTTON_POWER },

apps/keymaps/keymap-h10.c:90: { ACTION_WPS_VIEW_PLAYLIST, BUTTON_POWER|BUTTON_PLAY, BUTTON_NONE },

apps/keymaps/keymap-m200.c:68: { ACTION_WPS_ABSETB_NEXTDIR,BUTTON_POWER|BUTTON_RIGHT, BUTTON_POWER },
apps/keymaps/keymap-m200.c:69: { ACTION_WPS_ABSETA_PREVDIR,BUTTON_POWER|BUTTON_LEFT, BUTTON_POWER },
apps/keymaps/keymap-m200.c:70: { ACTION_WPS_ABRESET, BUTTON_POWER|BUTTON_UP, BUTTON_POWER },

apps/keymaps/keymap-c200.c:68: { ACTION_WPS_ABSETB_NEXTDIR,BUTTON_POWER|BUTTON_RIGHT, BUTTON_POWER },
apps/keymaps/keymap-c200.c:69: { ACTION_WPS_ABSETA_PREVDIR,BUTTON_POWER|BUTTON_LEFT, BUTTON_POWER },
apps/keymaps/keymap-c200.c:70: { ACTION_WPS_ABRESET, BUTTON_POWER|BUTTON_UP, BUTTON_POWER },

apps/keymaps/keymap-clip.c:68: { ACTION_WPS_ABSETB_NEXTDIR, BUTTON_POWER|BUTTON_RIGHT, BUTTON_POWER },
apps/keymaps/keymap-clip.c:69: { ACTION_WPS_ABSETA_PREVDIR, BUTTON_POWER|BUTTON_LEFT, BUTTON_POWER },
apps/keymaps/keymap-clip.c:70: { ACTION_WPS_ABRESET, BUTTON_POWER|BUTTON_UP, BUTTON_POWER },

apps/keymaps/keymap-e200.c:68: { ACTION_WPS_ABSETB_NEXTDIR, BUTTON_POWER|BUTTON_RIGHT, BUTTON_POWER },
apps/keymaps/keymap-e200.c:69: { ACTION_WPS_ABSETA_PREVDIR, BUTTON_POWER|BUTTON_LEFT, BUTTON_POWER },
apps/keymaps/keymap-e200.c:70: { ACTION_WPS_ABRESET, BUTTON_POWER|BUTTON_UP, BUTTON_POWER },

apps/keymaps/keymap-sa9200.c:83: { ACTION_WPS_ABSETB_NEXTDIR,BUTTON_POWER|BUTTON_NEXT, BUTTON_POWER },
apps/keymaps/keymap-sa9200.c:84: { ACTION_WPS_ABSETA_PREVDIR,BUTTON_POWER|BUTTON_PREV, BUTTON_POWER },
apps/keymaps/keymap-sa9200.c:85: { ACTION_WPS_ABRESET, BUTTON_POWER|BUTTON_UP, BUTTON_POWER },

Testing on my sansa the power off time is a good bit longer then the time needed for AB repeat, so it still works, but I don't know if this is acceptable to people.
Comment by Rafaël Carré (funman) - Saturday, 16 January 2010, 07:50 GMT
I think m200 and c100 are not used, so it only needs checking on

e200(v1/v2), sa9200, h10

Loading...