aboutsummaryrefslogtreecommitdiff
path: root/template/assemblies/switcher/audio.phtml
diff options
context:
space:
mode:
Diffstat (limited to 'template/assemblies/switcher/audio.phtml')
-rw-r--r--template/assemblies/switcher/audio.phtml101
1 files changed, 68 insertions, 33 deletions
diff --git a/template/assemblies/switcher/audio.phtml b/template/assemblies/switcher/audio.phtml
index fb12e60..9e42e0b 100644
--- a/template/assemblies/switcher/audio.phtml
+++ b/template/assemblies/switcher/audio.phtml
@@ -1,33 +1,68 @@
-<h3>Formats</h3>
-<ul>
- <li>
- <span class="label filetype">AUDIO</span>
- <a href="<?=h(link_player($room, 'audio'))?>">
- <span class="fa fa-flag-o"></span>
- native
- </a>
- <a href="<?=h(link_player($room, 'audio', true))?>">
- <span class="fa fa-flag"></span>
- translated
- </a>
- </li>
-</ul>
-
-<hr />
-
-<h3>Directlinks</h3>
-<ul>
- <? foreach(array('mp3', 'opus') as $iter): ?>
- <li>
- <span class="label filetype" title="<?=h(format_text($iter))?>"><?=h(strtoupper($iter))?></span>
- <a href="<?=h(link_stream('audio', $room, $iter))?>">
- <span class="fa fa-flag-o"></span>
- native
- </a>
- <a href="<?=h(link_stream('audio', $room, $iter, true))?>">
- <span class="fa fa-flag"></span>
- translated
- </a>
- </li>
- <? endforeach ?>
-</ul>
+<div class="container-fluid">
+ <h3>Audio</h3>
+ <div class="formats row">
+
+ <div class="col-lg-3 col-md-4 col-lg-5 col-xs-12">
+ <div class="btn-group" role="group">
+ <div class="btn btn-primary" disabled>Audio</div>
+
+ <? if($has_translation): ?>
+
+ <a href="<?=h(link_player($room, 'audio'))?>" class="btn btn-default">
+ <span class="fa fa-flag-o"></span>
+ native
+ </a>
+ <a href="<?=h(link_player($room, 'audio', true))?>" class="btn btn-default">
+ <span class="fa fa-flag"></span>
+ translated
+ </a>
+
+ <? else: ?>
+
+ <a href="<?=h(link_player($room, 'audio'))?>" class="btn btn-default">
+ <span class="fa fa-video-camera"></span>
+ video
+ </a>
+
+ <? endif ?>
+ </div>
+ </div>
+
+ </div>
+
+
+ <h3>Directlinks</h3>
+ <div class="formats row">
+
+ <? foreach(array_intersect($formats, array('audio-mp3', 'audio-opus')) as $format): ?>
+ <div class="col-lg-3 col-md-4 col-lg-5 col-xs-12">
+ <? $proto = substr($format, 6) ?>
+ <div class="btn-group" role="group">
+ <div class="btn btn-primary" disabled><?=h(strtoupper($proto))?></div>
+
+ <? if($has_translation): ?>
+
+ <a href="<?=h(link_stream('audio', $room, $proto))?>" class="btn btn-default">
+ <span class="fa fa-flag-o"></span>
+ native
+ </a>
+ <a href="<?=h(link_stream('audio', $room, $proto, true))?>" class="btn btn-default">
+ <span class="fa fa-flag"></span>
+ translated
+ </a>
+
+ <? else: ?>
+
+ <a href="<?=h(link_stream('audio', $room, $proto))?>" class="btn btn-default">
+ <span class="fa fa-video-camera"></span>
+ video
+ </a>
+
+ <? endif ?>
+
+ </div>
+ </div>
+ <? endforeach ?>
+
+ </div>
+</div> \ No newline at end of file