diff --git a/livesupport/modules/htmlUI/var/templates/filedata.tpl b/livesupport/modules/htmlUI/var/templates/file/data.tpl old mode 100755 new mode 100644 similarity index 100% rename from livesupport/modules/htmlUI/var/templates/filedata.tpl rename to livesupport/modules/htmlUI/var/templates/file/data.tpl diff --git a/livesupport/modules/htmlUI/var/templates/header.tpl b/livesupport/modules/htmlUI/var/templates/header.tpl index 1f6582e8e..0e8f14b00 100755 --- a/livesupport/modules/htmlUI/var/templates/header.tpl +++ b/livesupport/modules/htmlUI/var/templates/header.tpl @@ -27,6 +27,7 @@ {include file="script/basics.js.tpl"} {include file="script/contextmenu.js.tpl"} {include file="script/collector.js.tpl"} + {include file="script/alt.js.tpl"} diff --git a/livesupport/modules/htmlUI/var/templates/library/actionhandler.tpl b/livesupport/modules/htmlUI/var/templates/library/actionhandler.tpl new file mode 100755 index 000000000..3e4586d58 --- /dev/null +++ b/livesupport/modules/htmlUI/var/templates/library/actionhandler.tpl @@ -0,0 +1,36 @@ +onMouseover="showAlt('Some info about file ID {$i.id}')" +onMouseout="hideAlt()" +onClick="return contextmenu('{$i.id}' + , 'SP.addItem' + + {if $i.type == 'audioclip'} + , 'listen', '{$i.gunid}' + {if $_PL_activeId} + , 'PL.addItem' + {else} + , 'PL.create' + {/if} + , 'edit', 'delete' + {/if} + + {if $i.type == 'webstream'} + {if $_PL_activeId} + , 'PL.addItem' + {else} + , 'PL.create' + {/if} + , 'edit', 'delete' + {/if} + + {if $i.type == 'playlist'} + {if $_PL_activeId} + {if $_PL_activeId == $i.id} + , 'PL.release' + {else} + , 'PL.addItem', 'delete' + {/if} + {else} + , 'PL.activate', 'PL.create', 'delete' + {/if} + {/if} +)" diff --git a/livesupport/modules/htmlUI/var/templates/library/results.tpl b/livesupport/modules/htmlUI/var/templates/library/results.tpl index 1000566fe..01030f8dc 100755 --- a/livesupport/modules/htmlUI/var/templates/library/results.tpl +++ b/livesupport/modules/htmlUI/var/templates/library/results.tpl @@ -15,18 +15,18 @@ {foreach from=$_results.items item=i} - + - + {if $PLAYLIST.id == $i.id} {$i.title|truncate:30} {else} {$i.title|truncate:30} {/if} - {$i.creator} - {$i.duration} - {$i.type} + {$i.creator} + {$i.duration} + {$i.type} {/foreach} @@ -49,13 +49,13 @@ ##Range##: {$_criteria.offset+1}-{if ($_criteria.offset+$_criteria.limit)>$_results.cnt}{$_results.cnt}{else}{$_criteria.offset+$_criteria.limit}{/if} - - + {if $_PL_activeId} - + {else} - + {/if} + + +{/literal} diff --git a/livesupport/modules/htmlUI/var/templates/script/contextmenu.js.tpl b/livesupport/modules/htmlUI/var/templates/script/contextmenu.js.tpl index bcd28d767..cc7b410b1 100755 --- a/livesupport/modules/htmlUI/var/templates/script/contextmenu.js.tpl +++ b/livesupport/modules/htmlUI/var/templates/script/contextmenu.js.tpl @@ -1,202 +1,185 @@ {literal} - {/literal} diff --git a/livesupport/modules/htmlUI/var/templates/sub/contextmenu.tpl b/livesupport/modules/htmlUI/var/templates/sub/contextmenu.tpl index c87a8c72c..b1bd05eb5 100755 --- a/livesupport/modules/htmlUI/var/templates/sub/contextmenu.tpl +++ b/livesupport/modules/htmlUI/var/templates/sub/contextmenu.tpl @@ -1,6 +1,6 @@ {assign var="_PL_activeId" value=$PL->getActiveId()} -onContextmenu="return contextmenu('{$i.id}' +onClick="return contextmenu('{$i.id}' {$moreContextBefore} {if $i.type == 'audioclip'} , 'listen', '{$i.gunid}' @@ -39,6 +39,4 @@ onContextmenu="return contextmenu('{$i.id}' {$moreContextAfter} )" - -{assign var="moreContextBefore" value=""} -{assign var="moreContextAfter" value=""} +{assign var="_PL_activeId" value=NULL}