Ignore:
Timestamp:
Dec 9, 2012, 6:34:58 PM (12 years ago)
Author:
julien1311
Message:

add the capacity to choose the supported files

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/Media_Icon/template/media_icon_thumbnails.tpl

    r19352 r19372  
    1818{/literal}
    1919                //Youtube
    20                 $("img[media_icon^=youtube]").before('<span class="media_icon media_icon_youtube_{$media_icon_style}"></span>');
     20                {if $media_icon_support.youtube eq 1}$("img[media_icon^=youtube]").before('<span class="media_icon media_icon_youtube_{$media_icon_style}"></span>'){/if};
    2121                //Vimeo
    22                 $("img[media_icon^=vimeo]").before('<span class="media_icon media_icon_vimeo_{$media_icon_style}"></span>');
     22                {if $media_icon_support.vimeo eq 1}$("img[media_icon^=vimeo]").before('<span class="media_icon media_icon_vimeo_{$media_icon_style}"></span>'){/if};
    2323                //Dailymotion
    24                 $("img[media_icon^=dailymotion]").before('<span class="media_icon media_icon_dailymotion_{$media_icon_style}"></span>');
     24                {if $media_icon_support.dailymotion eq 1}$("img[media_icon^=dailymotion]").before('<span class="media_icon media_icon_dailymotion_{$media_icon_style}"></span>'){/if};
    2525                //Wat
    26                 $("img[media_icon^=wat]").before('<span class="media_icon media_icon_wat_{$media_icon_style}"></span>');
     26                {if $media_icon_support.wat eq 1}$("img[media_icon^=wat]").before('<span class="media_icon media_icon_wat_{$media_icon_style}"></span>'){/if};
    2727                //Wideo
    28                 $("img[media_icon^=wideo]").before('<span class="media_icon media_icon_wideo_{$media_icon_style}"></span>');
     28                {if $media_icon_support.wideo eq 1}$("img[media_icon^=wideo]").before('<span class="media_icon media_icon_wideo_{$media_icon_style}"></span>'){/if};
    2929                //Video
    30                 $("img[media_icon$=webm]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>');
    31                 $("img[media_icon$=webmv]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>');
    32                 $("img[media_icon$=ogv]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>');
    33                 $("img[media_icon$=m4v]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>');
    34                 $("img[media_icon$=flv]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>');
    35                 $("img[media_icon$=mp4]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>');
     30                {if $media_icon_support.video eq 1}$("img[media_icon$=webm]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>'){/if};
     31                {if $media_icon_support.video eq 1}$("img[media_icon$=webmv]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>'){/if};
     32                {if $media_icon_support.video eq 1}$("img[media_icon$=ogv]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>'){/if};
     33                {if $media_icon_support.video eq 1}$("img[media_icon$=m4v]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>'){/if};
     34                {if $media_icon_support.video eq 1}$("img[media_icon$=flv]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>'){/if};
     35                {if $media_icon_support.video eq 1}$("img[media_icon$=mp4]").before('<span class="media_icon media_icon_video_{$media_icon_style}"></span>'){/if};
    3636                //Music
    37                 $("img[media_icon$=mp3]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>');
    38                 $("img[media_icon$=ogg]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>');
    39                 $("img[media_icon$=oga]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>');
    40                 $("img[media_icon$=m4a]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>');
    41                 $("img[media_icon$=webma]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>');
    42                 $("img[media_icon$=fla]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>');
    43                 $("img[media_icon$=wav]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>');
     37                {if $media_icon_support.music eq 1}$("img[media_icon$=mp3]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>'){/if};
     38                {if $media_icon_support.music eq 1}$("img[media_icon$=ogg]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>'){/if};
     39                {if $media_icon_support.music eq 1}$("img[media_icon$=oga]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>'){/if};
     40                {if $media_icon_support.music eq 1}$("img[media_icon$=m4a]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>'){/if};
     41                {if $media_icon_support.music eq 1}$("img[media_icon$=webma]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>'){/if};
     42                {if $media_icon_support.music eq 1}$("img[media_icon$=fla]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>'){/if};
     43                {if $media_icon_support.music eq 1}$("img[media_icon$=wav]").before('<span class="media_icon media_icon_music_{$media_icon_style}"></span>'){/if};
    4444                //pdf
    45                 $("img[media_icon$=pdf]").before('<span class="media_icon media_icon media_icon_pdf_{$media_icon_style}"></span>');
     45                {if $media_icon_support.pdf eq 1}$("img[media_icon$=pdf]").before('<span class="media_icon media_icon media_icon_pdf_{$media_icon_style}"></span>'){/if};
    4646                //doc, docx or odt
    47                 $("img[media_icon$=doc]").before('<span class="media_icon media_icon_document_{$media_icon_style}"></span>');
    48                 $("img[media_icon$=docx]").before('<span class="media_icon media_icon_document_{$media_icon_style}"></span>');
    49                 $("img[media_icon$=odt]").before('<span class="media_icon media_icon_document_{$media_icon_style}"></span>');
     47                {if $media_icon_support.document eq 1}$("img[media_icon$=doc]").before('<span class="media_icon media_icon_document_{$media_icon_style}"></span>'){/if};
     48                {if $media_icon_support.document eq 1}$("img[media_icon$=docx]").before('<span class="media_icon media_icon_document_{$media_icon_style}"></span>'){/if};
     49                {if $media_icon_support.document eq 1}$("img[media_icon$=odt]").before('<span class="media_icon media_icon_document_{$media_icon_style}"></span>'){/if};
    5050                //xls, xlsx or ods
    51                 $("img[media_icon$=xls]").before('<span class="media_icon media_icon_spreadsheet_{$media_icon_style}"></span>');
    52                 $("img[media_icon$=xlsx]").before('<span class="media_icon media_icon_spreadsheet_{$media_icon_style}"></span>');
    53                 $("img[media_icon$=ods]").before('<span class="media_icon media_icon_spreadsheet_{$media_icon_style}"></span>');
     51                {if $media_icon_support.spreadsheet eq 1}$("img[media_icon$=xls]").before('<span class="media_icon media_icon_spreadsheet_{$media_icon_style}"></span>'){/if};
     52                {if $media_icon_support.spreadsheet eq 1}$("img[media_icon$=xlsx]").before('<span class="media_icon media_icon_spreadsheet_{$media_icon_style}"></span>'){/if};
     53                {if $media_icon_support.spreadsheet eq 1}$("img[media_icon$=ods]").before('<span class="media_icon media_icon_spreadsheet_{$media_icon_style}"></span>'){/if};
    5454                //ppt, pptx or odp
    55                 $("img[media_icon$=ppt]").before('<span class="media_icon media_icon_presentation_{$media_icon_style}"></span>');
    56                 $("img[media_icon$=pptx]").before('<span class="media_icon media_icon_presentation_{$media_icon_style}"></span>');
    57                 $("img[media_icon$=odp]").before('<span class="media_icon media_icon_presentation_{$media_icon_style}"></span>');
     55                {if $media_icon_support.presentation eq 1}$("img[media_icon$=ppt]").before('<span class="media_icon media_icon_presentation_{$media_icon_style}"></span>'){/if};
     56                {if $media_icon_support.presentation eq 1}$("img[media_icon$=pptx]").before('<span class="media_icon media_icon_presentation_{$media_icon_style}"></span>'){/if};
     57                {if $media_icon_support.presentation eq 1}$("img[media_icon$=odp]").before('<span class="media_icon media_icon_presentation_{$media_icon_style}"></span>'){/if};
    5858{literal}
    5959        }
Note: See TracChangeset for help on using the changeset viewer.