forked from openlp/openlp
remove prints
This commit is contained in:
parent
5f5d69d4d2
commit
071dfa6299
@ -230,39 +230,11 @@ class MediaController(RegistryMixin, OpenLPMixin, RegistryProperties):
|
||||
if self.current_media_players[DisplayControllerType.Preview].get_preview_state() is not MediaState.Playing:
|
||||
self.preview_timer.stop()
|
||||
else:
|
||||
print("A2")
|
||||
self.preview_timer.stop()
|
||||
self.media_stop(self.display_controllers[DisplayControllerType.Preview])
|
||||
if self.display_controllers[DisplayControllerType.Preview].media_info.loop_playback:
|
||||
self.media_play(self.display_controllers[DisplayControllerType.Preview], True)
|
||||
|
||||
# def media_state_preview(self):
|
||||
# """
|
||||
# Check if there is a running media preview Player and do updating stuff (e.g. update the UI)
|
||||
# """
|
||||
# if not list(self.current_media_players.keys()):
|
||||
# self.preview_timer.stop()
|
||||
# else:
|
||||
# any_active = False
|
||||
# for source in list(self.current_media_players.keys()):
|
||||
# display = self._define_display(self.display_controllers[source])
|
||||
# self.current_media_players[source].resize(display)
|
||||
# self.current_media_players[source].update_ui(display)
|
||||
# if self.current_media_players[source].get_preview_state() == MediaState.Playing:
|
||||
# any_active = True
|
||||
# self.tick(self.display_controllers[source])
|
||||
# # There are still any active players - no need to stop live_timer.
|
||||
# if any_active:
|
||||
# return
|
||||
# # no players are active anymore
|
||||
# for source in list(self.current_media_players.keys()):
|
||||
# if self.current_media_players[source].get_preview_state() != MediaState.Paused:
|
||||
# display = self._define_display(self.display_controllers[source])
|
||||
# display.controller.seek_slider.setSliderPosition(0)
|
||||
# display.controller.mediabar.actions['playbackPlay'].setVisible(True)
|
||||
# display.controller.mediabar.actions['playbackPause'].setVisible(False)
|
||||
# self.preview_timer.stop()
|
||||
|
||||
def get_media_display_css(self):
|
||||
"""
|
||||
Add css style sheets to htmlbuilder
|
||||
@ -692,12 +664,8 @@ class MediaController(RegistryMixin, OpenLPMixin, RegistryProperties):
|
||||
:param controller: The Controller to be processed
|
||||
"""
|
||||
start_again = False
|
||||
print("D")
|
||||
print(controller.media_info.playing, controller.media_info.length)
|
||||
if controller.media_info.playing and controller.media_info.length > 0:
|
||||
print(controller.media_info.timer, controller.media_info.length)
|
||||
if controller.media_info.timer > controller.media_info.length:
|
||||
print("D1")
|
||||
self.media_stop(controller, True)
|
||||
if controller.media_info.loop_playback:
|
||||
start_again = True
|
||||
@ -711,7 +679,6 @@ class MediaController(RegistryMixin, OpenLPMixin, RegistryProperties):
|
||||
controller.position_label.setText(' %02d:%02d / %02d:%02d' %
|
||||
(minutes, seconds, total_minutes, total_seconds))
|
||||
if start_again:
|
||||
print("D2")
|
||||
self.media_play(controller, True)
|
||||
|
||||
def media_pause_msg(self, msg):
|
||||
@ -768,10 +735,8 @@ class MediaController(RegistryMixin, OpenLPMixin, RegistryProperties):
|
||||
:param controller: The controller that needs to be stopped
|
||||
:param looping_background: The background is looping so do not blank.
|
||||
"""
|
||||
print("E")
|
||||
display = self._define_display(controller)
|
||||
if controller.controller_type in self.current_media_players:
|
||||
print("E1")
|
||||
if not looping_background:
|
||||
display.frame.evaluateJavaScript('show_blank("black");')
|
||||
self.current_media_players[controller.controller_type].stop(display)
|
||||
|
Loading…
Reference in New Issue
Block a user