mediaclipselectorform¶
-
class
openlp.plugins.media.forms.mediaclipselectorform.
MediaClipSelectorForm
(media_item, parent, manager)[source]¶ Bases:
PyQt5.QtWidgets.QDialog
,openlp.plugins.media.forms.mediaclipselectordialog.Ui_MediaClipSelector
,openlp.core.common.registryproperties.RegistryProperties
Class to manage the clip selection
-
detect_audio_cd
(path)[source]¶ Detects is the given path is an audio CD
Parameters: path – Path to the device to be tested. Returns: True if it was an audio CD else False.
-
find_optical_devices
()[source]¶ Attempt to autodetect optical devices on the computer, and add them to the media-dropdown :return:
-
media_state_wait
(media_state)[source]¶ Wait for the video to change its state Wait no longer than 15 seconds. (loading an optical disc takes some time)
Parameters: media_state – VLC media state to wait for. Returns: True if state was reached within 15 seconds, False if not or error occurred.
-
on_audio_tracks_combobox_currentIndexChanged
(index)[source]¶ When a new audio track is chosen update audio track bing played by VLC
Parameters: index – The index of the newly chosen audio track.
-
on_end_timeedit_timeChanged
(new_time)[source]¶ Called when end_timeedit is changed manually
Parameters: new_time – The new time
Set the player position to the position stored in end_timeedit
Parameters: clicked – Given from signal, not used.
Set the player position to the position stored in start_position_edit
Parameters: clicked – Given from signal, not used.
Load the media when the load-button has been clicked
Parameters: clicked – Given from signal, not used.
Toggle the playback
Parameters: clicked – Given from signal, not used.
-
on_position_slider_sliderMoved
(position)[source]¶ Set player position according to new slider position.
Parameters: position – Position to seek to.
Copy the current player position to end_timeedit
Parameters: clicked – Given from signal, not used.
Copy the current player position to start_position_edit
Parameters: clicked – Given from signal, not used.
-
on_start_timeedit_timeChanged
(new_time)[source]¶ Called when start_position_edit is changed manually
Parameters: new_time – The new time
-
on_subtitle_tracks_combobox_currentIndexChanged
(index)[source]¶ When a new subtitle track is chosen update subtitle track bing played by VLC
Parameters: index – The index of the newly chosen subtitle.
-
on_titles_combo_box_currentIndexChanged
(index)[source]¶ When a new title is chosen, it is loaded by VLC and info about audio and subtitle tracks is reloaded
Parameters: index – The index of the newly chosen title track.
-
toggle_disable_load_media
(action)[source]¶ Enable/disable load media combobox and button.
Parameters: action – If True elements are disabled, if False they are enabled.
-