I've been scanning through the outstanding issues and on reconsideration this looks reasonably easy to implement, though there are potential unexpected side-effects.
I think that the mapping F1, F2, F3, F4 for RED, GREEN, YELLOW, BLUE makes the most sense, especially since this context already exists:
Code: Select all
<map context="ShortcutActions">
<key id="KEY_F1" mapto="red" flags="mr"/>
<key id="KEY_F2" mapto="yellow" flags="mr"/>
<key id="KEY_F3" mapto="green" flags="mr"/>
<key id="KEY_F4" mapto="blue" flags="mr"/>
<key id="KEY_RED" mapto="red" flags="mr"/>
<key id="KEY_YELLOW" mapto="yellow" flags="mr"/>
<key id="KEY_GREEN" mapto="green" flags="mr"/>
<key id="KEY_BLUE" mapto="blue" flags="mr"/>
</map>
That context is used in the screens WebcamViewer, BackupRestore, SoftwareManager, WirelessLan, HarddiskSetup, InfoBarGenerics, NetworkSetup, PowerTimerEdit, TaskList and TimerEdit.
However, I don't think that the ordering makes much sense. I think it should be F1->RED, F2->GREEN, F3->YELLOW, F4->BLUE.
Extending the ColorActions context to allow the use of the same function buttons to be used instead of the colour buttons seems logical.
ShortcutActions and ColorActions differ in that the first allows for button repeats, and the second allows for long/short presses.
Other contexts where existing colour button presses might be paralleled by function buttons are:
SetupActions, InfobarInstantRecord, InfobarExtensions, SatlistShortcutAction (unused in Beyonwiz firmware), InfobarSubserviceSelectionActions (unused in Beyonwiz firmware), InfobarRedButtonActions, InfobarSeekActions, MediaPlayerSeekActions, TeletextActions, ChannelSelectBaseActions, EPGSelectActions, EventViewActions, EventViewEPGActions, MsgBoxActions.
Existing contexts that use function buttons are:
InfobarMenuActions, but it only uses F5, so there's no potential conflict there.
FunctionKeyActions uses F1-F3, but it isn't used in the Beyonwiz firmware or in enigma2-plugins (but other plugins are also used/available).
So it appears unlikely that using F1-F4 as alternative colour buttons in all contexts that use the coloured buttons is unlikely to cause problems.
The only other source of problems I can think of is that if plugins define their own contexts with coloured buttons, they most likely won't allow the use of the function buttons as alternatives for the coloured buttons. That can be fixed for plugins in the Beyonwiz repository that have their own keymap.xml files, like CutListEditor.
If anyone's interested in trying it out, I'm happy to make a patch for you to try.