Posts: 144
Joined: Aug 2010
Reputation:
2
I've just worked out that it is possible to get my original functionality change put in via keymap.xml changes... but only if done from the system file, the per-user one gives that odd behaviour.
In interests of getting this in without treading into detangling a mess, I'll edit the various keymaps. (Then read up on git to know how to submit the changes.) This will fix the original reason for the post.
But if you want to continue talking about potential consolidation of actions, fixing back/parentdir/previousmenu should I edit the thread's title? (If the forum is set up to allow me?)
Posts: 26,215
Joined: Oct 2003
Reputation:
187
From the code it appears that the ParentDir action is handled already in 99% of windows (all dialogs, skin windows and media windows), so mapping it in the <global> section is all that should be needed.
If it's needed anywhere else then we fix it in the code.
Cheers,
Jonathan
Posts: 144
Joined: Aug 2010
Reputation:
2
2011-07-05, 15:07
(This post was last modified: 2011-07-05, 20:21 by barberio.)
Where do I email in patches?
Edit: Never mind, set up a github account and sent a pull request.
Posts: 144
Joined: Aug 2010
Reputation:
2
Okay, I think I've gotten a little confused over what I thought you were asking me to do. I thought you were agreeing we should deprecate PreviousMenu in favour of ParentDir as the implementation of 'back' functionality, and that since most of the code already does that it would be quickest to shake things down by providing a patch set that removes it so testers can identify what breaks.
So far I'd found the following breakage from those that had specific exceptions defined in keymaps so could be expected to
* SlideShow,
* Any Menu Player Controls when nothing is playing. (This might be a bug, since it doesn't bring up the controls, but acts like a new window has been entered?)
* Settings - Profiles
* System Status
(Not that I know where to start in fixing those beyond a sticking plaster of putting back their exception, which would just punt the problem...)
But it's not just a matter of identifying what currently has an exception in the keymaps, and checking those, because some places may expect the user to "know" to use escape over backspace to get out of their menu/window and never changed the keymaps. So there needs to be a way to identify those, and without some automated test framework that means providing a build with PreviousMenu keymaps turned off so people can find what breaks and fix it.
Posts: 245
Joined: May 2010
Reputation:
0
Thank you! This is a great idea from a usability standpoint. MCE (ugh) has it right on this. Hitting back while at the home screen switched back to the currently playing media. I have seen my wife and friends get confused by this a number of times on how to switch back to "now playing" basically.
Posts: 26,215
Joined: Oct 2003
Reputation:
187
@barberio: I'm going to change it so that ParentDir == Back and introduce ParentFolder for the "new" parent dir function. That gives backward compat, so we can monkey the keymaps and nothing (theoretically) breaks.
Cheers,
Jonathan
Posts: 26,215
Joined: Oct 2003
Reputation:
187
Pushed the pull req in, and the keymaps are done.
Next step is taking care of what this thread wanted to do - I'll leave that to you, but handling that in CGUIWindowHome::OnAction() seems most reasonable to me.
Cheers,
Jonathan