Opened 19 years ago
Closed 19 years ago
Last modified 18 years ago
#2078 closed enhancement (fixed)
Better mythcontrols UI and reorganizes logic
Reported by: | Owned by: | danielk | |
---|---|---|---|
Priority: | minor | Milestone: | 0.21 |
Component: | mythcontrols | Version: | head |
Severity: | low | Keywords: | mythcontrols ui logic |
Cc: | Ticket locked: | no |
Description
I'm not sure when, but not long after the release of 0.19 someone added some code to add alternate methods of browsing key bindings. A great idea, but the implementation looked poor and added alot of code to mythcontrols.cpp.
The attached patch removes most of that extra code (in favour of using the keybindings class, as was originally intended for this plugin) and improves (I think) the alternate views.
Deleting from the alternate views will be easier with these modifications, and maybe someone will think of a novel way to add bindings that works well too. I do plan on adding the code to facilitate deletion soon.
Attachments (8)
Change History (18)
by , 19 years ago
Attachment: | ui_and_logic.diff added |
---|
comment:1 by , 19 years ago
Milestone: | → 0.21 |
---|---|
Owner: | changed from | to
Version: | → head |
Micah, I'll have a look at this after the release. But in the meantime please reformat the additions in the MythTV coding style. A separate reformating patch for the existing code would be welcomed as well.
comment:3 by , 19 years ago
Resolution: | invalid |
---|---|
Status: | closed → reopened |
OK, formatting of the entire plugin is fixed with this patch. This also has the modifications that the last patch had.
comment:4 by , 19 years ago
Resolution: | → invalid |
---|---|
Status: | reopened → closed |
The reformatting of existing code needs to be in a separate patch from new code additions and functional modifications.
by , 19 years ago
Attachment: | standard_formatting.diff added |
---|
Fixes mythcontrols to use MythTV coding standards
comment:5 by , 19 years ago
Resolution: | invalid |
---|---|
Status: | closed → reopened |
comment:6 by , 19 years ago
(In [11515]) Refs #2078. Cleanup of MythControls. Should not change functionality.
This applies Micah's cleanup patch + additional cleanups + adds plugins to the doxygen documentation.
comment:7 by , 19 years ago
I'm having following problems with SVN 11533:
When trying to remove e.g. key 'O' / TOGGLEBROWSE from the TV Playback context, mythcontrols mixes the context. It shows dialog: "Confirm - Delete this key binding from context Music?". If Confirm is selected, there's an error about telling that this is mandatory action.
Following shows this from the DB:
mysql> select context, action, keylist from keybindings where keylist = 'O'; +-------------+--------------+---------+ | context | action | keylist | +-------------+--------------+---------+ | TV Frontend | UPCOMING | O | | TV Playback | TOGGLEBROWSE | O | | Music | STOP | O | +-------------+--------------+---------+
If I go to Music, I can delete the 'O' binding from there and it really removes the Music binding.
Even if I add a second key binding to TV Playback, TV Frontend and Music, mythcontrols still won't let me delete the 'O' keybinding from the TV Playback. It says it's mandatory action.
mysql> select context, action, keylist from keybindings where keylist like '%O,%'; +-------------+--------------+----------+ | context | action | keylist | +-------------+--------------+----------+ | TV Frontend | UPCOMING | O,Ctrl+D | | TV Playback | TOGGLEBROWSE | O,Ctrl+A | | Music | STOP | O,Ctrl+D | +-------------+--------------+----------+
Just to verify that there are no actions that have only the 'O' mapping, which would justify the "mandatory error message":
mysql> select context, action, keylist from keybindings where keylist = 'O'; Empty set (0.00 sec)
So it seems to get confused from which context user want's to delete a key. And also fails to correctly identify a mandatory action.
Previous example is not the only one that fails for me, just an example.
comment:8 by , 19 years ago
The problem is with Binding class, which shouldn't ever have been added. I will attach a patch to fix the problem.
by , 19 years ago
Attachment: | fix_remove.diff added |
---|
Uses the correct context when removing keys from an action.
by , 19 years ago
Attachment: | view_menu.diff added |
---|
Uses a menu to change the views instead of "magic keys." This does not change the way that alternate views display information. This patch replaces the previous (fix_remove.diff) patch.
comment:9 by , 19 years ago
There are still problems with 2078-v1.patch:
The "Context By Keys" view has "Context" in the title above the list of keys, and "Actions" above the list of contexts. Also it allows you to enter a key binding when you select the context.
The "Keys By Context" view shows keys in the action pane, not actions.
The Change View menu only shows the other views. This is confusing, it should show all three views in the same order, but grey out the button for the current view. Some people have much better spatial memory than textual memory.
When you exit the key editor it crashes in UpdateRightList() when m_leftList->GetItemCurrent() returns null. (I've sent a backtrace to Micah for this.)
comment:10 by , 19 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
(In [13146]) Fixes #2078. Applies Micah's patch to improve MythControls UI and reorganize the logic for the views.
The only user visible change are formatting changes and a menu for switching views, but this also cleans up how the views are handled internally. The extra views are still informative only.
The patch (no deletion)