[mythtv] Some questions about the code
Carl Reynolds
mythtv-dev at hyperbole-software.com
Mon Nov 20 18:08:43 UTC 2006
young boy wrote:
>Hi Carl,
>
>Thank you for an invaluable inputs. So what tag in the xml that requires
>callback and addScreen.
>
>
>
Both Jump and callback are placed in an <action>...</action> tag as follows:
<action>Jump Jump Point Name</action>
<action>CallBack Name</action>
Note: that you just place the bare Callback Name in the tag with no
modifier to indicate what it is. The Jump has the modifier Jump, to tell
myththemedmenu that it is a jump point name and a Menu has the modifier
Menu, etc.
The possible modifiers for an action tag are EXEC, EXECTV, MENU, UPMENU,
CONFIGPLUGIN, PLUGIN, SHUTDOWN, and JUMP. If the action tag doesn't
start with any of these, the action is assumed to contain a Callback
Name which will be passed as an argument to the callback function.
To use the callback you will need to add the Callback Name into the list
of recognized names in TVMenuCallback in main.cpp of mythfrontend. This
function has a large if (sel == "...") else if (sel == "...") block.
Each of the string-constants is a Callback Name and may be placed in an
<action> tag. You would add new Callback Names to this list of 'if (...)
else's.
AddScreen is apparently part of the new mythui library. It was added in
version 0.20 and I'm not as familiar with it. However. it seems to add a
new screen to the user interface tree when the program sees <action>Menu
MenuName</action>
Carl.
More information about the mythtv-dev
mailing list