def play(self, end_callback, show_ready_callback, parent_kickback_signal, level, controls_list): """ displays the menu end_callback - function to be called when the menu exits show_ready_callback - callback when menu is ready to display (not used) level is 0 when the show is top level (run from [start] or from show control) parent_kickback_signal - not used other than it being passed to a show """ # need to instantiate the medialist here as not using gapshow self.medialist = MediaList("ordered") Show.base_play(self, end_callback, show_ready_callback, parent_kickback_signal, level, controls_list) self.mon.trace(self, self.show_params["show-ref"]) # parse the show and track timeouts reason, message, self.show_timeout = Show.calculate_duration(self, self.show_params["show-timeout"]) if reason == "error": self.mon.err(self, "Show Timeout has bad time: " + self.show_params["show-timeout"]) self.end("error", "show timeout, bad time") reason, message, self.track_timeout = Show.calculate_duration(self, self.show_params["track-timeout"]) if reason == "error": self.mon.err(self, "Track Timeout has bad time: " + self.show_params["track-timeout"]) self.end("error", "track timeout, bad time") # and delete eggtimer if self.previous_shower is not None: self.previous_shower.delete_eggtimer() # and display the menu self.do_menu_track()
def play(self,end_callback,show_ready_callback, parent_kickback_signal,level,controls_list): self.mon.newline(3) self.mon.trace(self, self.show_params['show-ref']) Show.base_play(self,end_callback,show_ready_callback,parent_kickback_signal, level,controls_list) # unpack show parameters reason,message,self.show_timeout = Show.calculate_duration(self,self.show_params['show-timeout']) if reason=='error': self.mon.err(self,'ShowTimeout has bad time: '+self.show_params['show-timeout']) self.end('error','ShowTimeout has bad time: '+self.show_params['show-timeout']) self.track_count_limit = int(self.show_params['track-count-limit']) reason,message,self.interval = Show.calculate_duration (self, self.show_params['interval']) if reason=='error': self.mon.err(self,'Interval has bad time: '+self.show_params['interval']) self.end('error','Interval has bad time: '+self.show_params['interval']) if self.medialist.anon_length()==0 and self.show_params['type'] not in ('liveshow','artliveshow'): self.mon.err(self,'No anonymous tracks in medialist ') self.end('error','No anonymous tracks in medialist ') # delete eggtimer started by the parent if self.previous_shower is not None: self.previous_shower.delete_eggtimer() self.start_show()
def play(self, end_callback, show_ready_callback, parent_kickback_signal, level, controls_list): self.mon.newline(3) self.mon.trace(self, self.show_params['show-ref']) Show.base_play(self, end_callback, show_ready_callback, parent_kickback_signal, level, controls_list) # unpack show parameters reason, message, self.show_timeout = Show.calculate_duration( self, self.show_params['show-timeout']) if reason == 'error': self.mon.err( self, 'ShowTimeout has bad time: ' + self.show_params['show-timeout']) self.end( 'error', 'ShowTimeout has bad time: ' + self.show_params['show-timeout']) self.track_count_limit = int(self.show_params['track-count-limit']) reason, message, self.interval = Show.calculate_duration( self, self.show_params['interval']) if reason == 'error': self.mon.err( self, 'Interval has bad time: ' + self.show_params['interval']) self.end('error', 'Interval has bad time: ' + self.show_params['interval']) # delete eggtimer started by the parent if self.previous_shower is not None: self.previous_shower.delete_eggtimer() self.start_show()
def play(self,end_callback,show_ready_callback,parent_kickback_signal,level,controls_list): """ starts the hyperlink show at start-track end_callback - function to be called when the show exits show_ready_callback - callback to get the previous track level is 0 when the show is top level (run from [start] or from show control) parent_kickback_signal - not used other than it being passed to a show """ # need to instantiate the medialist here as in gapshow done in derived class self.medialist=MediaList('ordered') Show.base_play(self,end_callback,show_ready_callback, parent_kickback_signal,level,controls_list) self.mon.trace(self,self.show_params['show-ref']) #parse the show and track timeouts reason,message,self.show_timeout=Show.calculate_duration(self,self.show_params['show-timeout']) if reason =='error': self.mon.err(self,'Show Timeout has bad time: '+self.show_params['show-timeout']) self.end('error','show timeout, bad time: '+self.show_params['show-timeout']) reason,message,self.track_timeout=Show.calculate_duration(self,self.show_params['track-timeout']) if reason=='error': self.mon.err(self,'Track Timeout has bad time: '+self.show_params['track-timeout']) self.end('error','track timeout, bad time: '+self.show_params['track-timeout']) # and delete eggtimer if self.previous_shower is not None: self.previous_shower.delete_eggtimer() self.do_first_track()
def play(self,end_callback,show_ready_callback, parent_kickback_signal,level,controls_list): self.mon.newline(3) self.mon.trace(self, self.show_params['show-ref']) Show.base_play(self,end_callback,show_ready_callback,parent_kickback_signal, level,controls_list) # unpack show parameters reason,message,self.show_timeout = Show.calculate_duration(self,self.show_params['show-timeout']) if reason=='error': self.mon.err(self,'ShowTimeout has bad time: '+self.show_params['show-timeout']) self.end('error','ShowTimeout has bad time: '+self.show_params['show-timeout']) self.track_count_limit = int(self.show_params['track-count-limit']) reason,message,self.interval = Show.calculate_duration (self, self.show_params['interval']) if reason=='error': self.mon.err(self,'Interval has bad time: '+self.show_params['interval']) self.end('error','Interval has bad time: '+self.show_params['interval']) if self.medialist.anon_length()==0 and self.show_params['type'] not in ('liveshow','artliveshow'): self.mon.err(self,'No anonymous tracks in medialist ') self.end('error','No anonymous tracks in medialist ') if self.show_params['trigger-next-type']=='input': self.wait_for_next_trigger=True else: self.wait_for_next_trigger=False # delete eggtimer started by the parent if self.previous_shower is not None: self.previous_shower.delete_eggtimer() self.playing_track=False self.start_show()
def play(self, end_callback, show_ready_callback, parent_kickback_signal, level, controls_list): """ starts the hyperlink show at start-track end_callback - function to be called when the show exits show_ready_callback - callback to get previous show and track level is 0 when the show is top level (run from [start] or from show control) parent_kickback_signal is not used passed to subshow by base class as parent_kickback_signal """ # need to instantiate the medialist here as in gapshow done in derived class self.medialist = MediaList('ordered') Show.base_play(self, end_callback, show_ready_callback, parent_kickback_signal, level, controls_list) #dummy as it gets passed down to subshow, however it isn't actuallly used. self.controls_list = [] self.mon.trace(self, self.show_params['show-ref']) # read show destinations self.first_track_ref = self.show_params['first-track-ref'] self.home_track_ref = self.show_params['home-track-ref'] self.timeout_track_ref = self.show_params['timeout-track-ref'] #parse the show and track timeouts reason, message, self.show_timeout = Show.calculate_duration( self, self.show_params['show-timeout']) if reason == 'error': self.mon.err( self, 'Show Timeout has bad time: ' + self.show_params['show-timeout']) self.end( 'error', 'show timeout, bad time: ' + self.show_params['show-timeout']) reason, message, self.track_timeout = Show.calculate_duration( self, self.show_params['track-timeout']) if reason == 'error': self.mon.err( self, 'Track Timeout has bad time: ' + self.show_params['track-timeout']) self.end( 'error', 'track timeout, bad time: ' + self.show_params['track-timeout']) # and delete eggtimer if self.previous_shower is not None: self.previous_shower.delete_eggtimer() self.do_first_track()
def play(self,end_callback,show_ready_callback,parent_kickback_signal,level,controls_list): """ starts the hyperlink show at start-track end_callback - function to be called when the show exits show_ready_callback - callback to get previous show and track level is 0 when the show is top level (run from [start] or from show control) parent_kickback_signal is not used passed to subshow by base class as parent_kickback_signal """ # need to instantiate the medialist here as in gapshow done in derived class self.medialist=MediaList('ordered') Show.base_play(self,end_callback,show_ready_callback, parent_kickback_signal,level,controls_list) #dummy as it gets passed down to subshow, however it isn't actuallly used. self.controls_list=[] self.mon.trace(self, self.show_params['show-ref']) # read show destinations self.first_track_ref=self.show_params['first-track-ref'] self.home_track_ref=self.show_params['home-track-ref'] self.timeout_track_ref=self.show_params['timeout-track-ref'] #parse the show and track timeouts reason,message,self.show_timeout=Show.calculate_duration(self,self.show_params['show-timeout']) if reason =='error': self.mon.err(self,'Show Timeout has bad time: '+self.show_params['show-timeout']) self.end('error','show timeout, bad time: '+self.show_params['show-timeout']) reason,message,self.track_timeout=Show.calculate_duration(self,self.show_params['track-timeout']) if reason=='error': self.mon.err(self,'Track Timeout has bad time: '+self.show_params['track-timeout']) self.end('error','track timeout, bad time: ' +self.show_params['track-timeout']) # and delete eggtimer if self.previous_shower is not None: self.previous_shower.delete_eggtimer() self.do_first_track()