Compare commits
2 commits
7fcd9113c3
...
25b896c41d
| Author | SHA1 | Date | |
|---|---|---|---|
| 25b896c41d | |||
| d72c63b2e5 |
4 changed files with 16 additions and 5 deletions
|
|
@ -4,6 +4,7 @@ import (
|
||||||
"bufio"
|
"bufio"
|
||||||
"fmt"
|
"fmt"
|
||||||
"os/exec"
|
"os/exec"
|
||||||
|
"sort"
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
)
|
)
|
||||||
|
|
@ -182,6 +183,10 @@ func ParseAmixerContent(cardId string) ([]*CardControl, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
err = cmd.Wait()
|
err = cmd.Wait()
|
||||||
|
|
||||||
|
// Sort mixers by NumID
|
||||||
|
sort.Sort(ByNumID(ret))
|
||||||
|
|
||||||
return ret, err
|
return ret, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -202,3 +207,9 @@ func (cc *CardControl) CsetAmixer(cardId string, values ...string) error {
|
||||||
|
|
||||||
return cmd.Wait()
|
return cmd.Wait()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type ByNumID []*CardControl
|
||||||
|
|
||||||
|
func (a ByNumID) Len() int { return len(a) }
|
||||||
|
func (a ByNumID) Swap(i, j int) { a[i], a[j] = a[j], a[i] }
|
||||||
|
func (a ByNumID) Less(i, j int) bool { return a[i].NumID < a[j].NumID }
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@
|
||||||
{#if (showInactives && $inputsList.length === 0) || (!showInactives && $activeInputs.length === 0)}
|
{#if (showInactives && $inputsList.length === 0) || (!showInactives && $activeInputs.length === 0)}
|
||||||
<li class="list-group-item py-3">
|
<li class="list-group-item py-3">
|
||||||
<span class="text-muted">
|
<span class="text-muted">
|
||||||
Aucune source active.
|
No active source.
|
||||||
</span>
|
</span>
|
||||||
</li>
|
</li>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
|
||||||
|
|
@ -27,7 +27,7 @@
|
||||||
|
|
||||||
{#if $activeSources.length === 0 && $activeInputs.length === 0}
|
{#if $activeSources.length === 0 && $activeInputs.length === 0}
|
||||||
<div class="text-muted text-center mt-1 mb-1">
|
<div class="text-muted text-center mt-1 mb-1">
|
||||||
Aucune source active pour l'instant.
|
No active audio source currently.
|
||||||
</div>
|
</div>
|
||||||
{:else}
|
{:else}
|
||||||
<marquee>
|
<marquee>
|
||||||
|
|
@ -38,7 +38,7 @@
|
||||||
{#if source.currentTitle}
|
{#if source.currentTitle}
|
||||||
<strong>{source.currentTitle}</strong> <span class="text-muted">@ {source.name}</span>
|
<strong>{source.currentTitle}</strong> <span class="text-muted">@ {source.name}</span>
|
||||||
{:else}
|
{:else}
|
||||||
{source.name} activée
|
{source.name} enabled
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -55,7 +55,7 @@
|
||||||
{/each}
|
{/each}
|
||||||
<span class="text-muted">@ {input.name}</span>
|
<span class="text-muted">@ {input.name}</span>
|
||||||
{:else}
|
{:else}
|
||||||
{input.name} activée
|
{input.name} enabled
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -52,7 +52,7 @@
|
||||||
<div class="d-flex justify-content-between">
|
<div class="d-flex justify-content-between">
|
||||||
<div>
|
<div>
|
||||||
<i class="bi bi-speaker"></i>
|
<i class="bi bi-speaker"></i>
|
||||||
Sources
|
Inputs
|
||||||
</div>
|
</div>
|
||||||
<button
|
<button
|
||||||
class="btn btn-sm"
|
class="btn btn-sm"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue