mirror of
https://github.com/pkali/piradio-mini.git
synced 2026-05-20 22:34:22 +02:00
Revert streaming on/off procedures changes.
This commit is contained in:
+1
-3
@@ -449,7 +449,6 @@ class Radio:
|
|||||||
# Icecast Streaming settings
|
# Icecast Streaming settings
|
||||||
self.streaming = self.getStoredStreaming()
|
self.streaming = self.getStoredStreaming()
|
||||||
if self.streaming:
|
if self.streaming:
|
||||||
self.streaming = False
|
|
||||||
self.streamingOn()
|
self.streamingOn()
|
||||||
else:
|
else:
|
||||||
self.streamingOff()
|
self.streamingOff()
|
||||||
@@ -1401,7 +1400,6 @@ class Radio:
|
|||||||
|
|
||||||
# Switch on Icecast2 streaming
|
# Switch on Icecast2 streaming
|
||||||
def streamingOn(self):
|
def streamingOn(self):
|
||||||
if not self.streaming:
|
|
||||||
output_id = 2
|
output_id = 2
|
||||||
self.streaming = True
|
self.streaming = True
|
||||||
self.execCommand("service icecast2 start")
|
self.execCommand("service icecast2 start")
|
||||||
@@ -1409,11 +1407,11 @@ class Radio:
|
|||||||
self.execMpcCommand("enable " + str(output_id))
|
self.execMpcCommand("enable " + str(output_id))
|
||||||
self.storeStreaming("on")
|
self.storeStreaming("on")
|
||||||
self.streamingStatus()
|
self.streamingStatus()
|
||||||
|
self.streammetadata = ''
|
||||||
return self.streaming
|
return self.streaming
|
||||||
|
|
||||||
# Switch off Icecast2 streaming
|
# Switch off Icecast2 streaming
|
||||||
def streamingOff(self):
|
def streamingOff(self):
|
||||||
if self.streaming:
|
|
||||||
output_id = 2
|
output_id = 2
|
||||||
self.streaming = False
|
self.streaming = False
|
||||||
self.execMpcCommand("disable " + str(output_id))
|
self.execMpcCommand("disable " + str(output_id))
|
||||||
|
|||||||
Reference in New Issue
Block a user