Initial commit
This commit is contained in:
commit
37196a07ec
72
gui
Executable file
72
gui
Executable file
@ -0,0 +1,72 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
GTKDIALOG=gtkdialog
|
||||||
|
|
||||||
|
radioBtn() {
|
||||||
|
echo '<button>
|
||||||
|
<label>'$1'</label>
|
||||||
|
<action>./play "'$2'"</action>
|
||||||
|
</button>'
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
MAIN_DIALOG='
|
||||||
|
<window title="Radio">
|
||||||
|
<vbox>
|
||||||
|
<hbox>
|
||||||
|
'"`radioBtn "Radio 1" http://bbcmedia.ic.llnwd.net/stream/bbcmedia_radio1_mf_p`"'
|
||||||
|
'"`radioBtn "Radio 2" http://bbcmedia.ic.llnwd.net/stream/bbcmedia_radio2_mf_p`"'
|
||||||
|
'"`radioBtn "Radio 3" http://bbcmedia.ic.llnwd.net/stream/bbcmedia_radio3_mf_p`"'
|
||||||
|
'"`radioBtn "Radio 4" http://bbcmedia.ic.llnwd.net/stream/bbcmedia_radio4fm_mf_p`"'
|
||||||
|
'"`radioBtn "Radio 4 Extra" http://bbcmedia.ic.llnwd.net/stream/bbcmedia_radio4extra_mf_p`"'
|
||||||
|
'"`radioBtn "Radio 5 Live" http://bbcmedia.ic.llnwd.net/stream/bbcmedia_radio5live_mf_p`"'
|
||||||
|
'"`radioBtn "Radio 6 Music" http://bbcmedia.ic.llnwd.net/stream/bbcmedia_6music_mf_p`"'
|
||||||
|
</hbox>
|
||||||
|
<hbox>
|
||||||
|
'"`radioBtn "BBC Cornwall" http://bbcmedia.ic.llnwd.net/stream/bbcmedia_lrcorn_mf_p`"'
|
||||||
|
'"`radioBtn "BBC Devon" http://bbcmedia.ic.llnwd.net/stream/bbcmedia_lrdevon_mf_p`"'
|
||||||
|
'"`radioBtn "Pirate FM" https://str4.sad.ukrd.com/pirate?rp=3.1.2&ts=1553703504&norequeue=1`"'
|
||||||
|
</hbox>
|
||||||
|
<hbox>
|
||||||
|
'"`radioBtn "R1 Dubstep" https://streaming.radionomy.com/R1Dubstep`"'
|
||||||
|
'"`radioBtn "R1 Melodic Dubstep" https://streaming.radionomy.com/R1MelodicDubstep`"'
|
||||||
|
'"`radioBtn "Dubstep.fm" https://www.dubstep.fm/256aac.m3u`"'
|
||||||
|
'"`radioBtn "Dubstep Radio" http://198.15.94.34:8018/stream`"'
|
||||||
|
</hbox>
|
||||||
|
<hbox>
|
||||||
|
'"`radioBtn "HBR1 Tranceponder" http://radio.hbr1.com:19800/trance.ogg.m3u`"'
|
||||||
|
'"`radioBtn "HBR1 Tronic Lounge" http://radio.hbr1.com:19800/tronic.ogg.m3u`"'
|
||||||
|
'"`radioBtn "HBR1 Dream Factory" http://radio.hbr1.com:19800/ambient.ogg.m3u`"'
|
||||||
|
</hbox>
|
||||||
|
<hbox>
|
||||||
|
'"`radioBtn "Rock Radio Beograd" http://ca6.rcast.net:4020/\;stream.mp3`"'
|
||||||
|
</hbox>
|
||||||
|
<text wrap="false" xalign="0.5" selectable="true">
|
||||||
|
<variable>txtTitles</variable>
|
||||||
|
<label>This text will be overwritten with the data from the command.</label>
|
||||||
|
<input>tail -n100 /tmp/play | grep icy-title | sed -e 's/icy-title://' | tail -n1</input>
|
||||||
|
</text>
|
||||||
|
<timer interval="1" visible="false">
|
||||||
|
<action>refresh:txtTitles</action>
|
||||||
|
</timer>
|
||||||
|
|
||||||
|
<hbox>
|
||||||
|
<button>
|
||||||
|
<input file icon="text-x-generic"></input>
|
||||||
|
<label>Info</label>
|
||||||
|
<action>tail -n100 /tmp/play | tac | zenity --height=10000 --width=10000 --text-info </action>
|
||||||
|
</button>
|
||||||
|
<button cancel></button>
|
||||||
|
</hbox>
|
||||||
|
</vbox>
|
||||||
|
</window>
|
||||||
|
'
|
||||||
|
export MAIN_DIALOG
|
||||||
|
|
||||||
|
case $1 in
|
||||||
|
-d | --dump) echo "$MAIN_DIALOG" ;;
|
||||||
|
*) $GTKDIALOG --space-expand=true --space-fill=true --program=MAIN_DIALOG ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
killall mpv
|
||||||
|
|
Loading…
Reference in New Issue
Block a user