Kodi Community Forum

Full Version: grouplist skinshortcuts onup action
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have a problem with the onup behaviour. The situation is like so:
A grouplist with skinshrtcuts widgets. I want to have specific onup conditions. The problem ist, that e.g. the <onup>300</onup> isn't working in the skinshortcuts widgets. It does nothing and i don't know, why Sad


Grouplist 
xml:
<control type="grouplist" id="301">
    <height>770</height>
    <orientation>vertical</orientation>
    <bottom>188</bottom>
    <width>2385</width>               
    <scrolltime tween="quadratic">400</scrolltime>
    <usecontrolcoords>true</usecontrolcoords>
    <itemgap>0</itemgap>

    <!-- Widget 1 -->                     
    <include>skinshortcuts-template-widget-vertical.1</include>                       
    <!-- Widget 2 -->
    <include>skinshortcuts-template-widget-vertical.2</include>     
    <!-- Widget 3 -->
    <include>skinshortcuts-template-widget-vertical.3</include>   
    [....]               
</control> 


Widget 1
xml:
<other include="widget-vertical.1">
    <property name="id" tag="mainmenuid" />
    [...]     
    <controls>            
        <control type="group" id="301$SKINSHORTCUTS[id]21"> 
            <control type="grouplist">                    
                [...]              
            </control>
        </control>  
        <control type="$SKINSHORTCUTS[widgetlisttype]" id="301$SKINSHORTCUTS[id]1">
            <onup>300</onup>                
            <visible>Integer.IsGreater(Container(301$SKINSHORTCUTS[id]1).NumItems,0) | Container(301$SKINSHORTCUTS[id]1).IsUpdating</visible>
            <skinshortcuts>visibility</skinshortcuts>                  
            <include content="TemplateItemLayout">
                 <param name="shortcutsid" value="301$SKINSHORTCUTS[id]1" />
           </include>
           <include content="TemplateFocusLayout">
                 <param name="shortcutsid" value="301$SKINSHORTCUTS[id]1" />
           </include>
           <content limit="$VAR[DefWidgetLimit]" target="$SKINSHORTCUTS[target]" sortby="$SKINSHORTCUTS[sortby]" sortorder="$SKINSHORTCUTS[sort]">$SKINSHORTCUTS[content]</content>
        </control>
    </controls>
</other>

Can someone help?
Wrap the widget inside it's own group control e.g.
xml:

<control type="grouplist">
<control type="group">
<visible>Integer.IsGreater(Container(301$SKINSHORTCUTS[id]1).NumItems,0) | Container(301$SKINSHORTCUTS[id]1).IsUpdating</visible>
<skinshortcuts>visibility</skinshortcuts>
<control type="$SKINSHORTCUTS[widgetlisttype]" id="301$SKINSHORTCUTS[id]1">
(might need to play with where the visibility controls go, also don't forget to make the size/position of the group the same as what the widget would be)

List/Button controls at base level of grouplist have ondirection overridden by Kodi to be next item in grouplist. Putting it inside its own group overrides this behaviour because it makes the group the parent control instead of the grouplist.
Thanks for your explanation, i'll try Smile