mediaitem

class openlp.plugins.presentations.lib.mediaitem.PresentationMediaItem(parent, plugin, controllers)[source]

Bases: openlp.core.lib.mediamanageritem.MediaManagerItem

This is the Presentation media manager item for Presentation Items. It can present files using Openoffice and Powerpoint

add_end_header_bar()[source]

Display custom media manager items for presentations.

build_file_mask_string()[source]

Build the list of file extensions to be used in the Open file dialog.

clean_up_thumbnails(filepath, clean_for_update=False)[source]

Clean up the files created such as thumbnails

Parameters:
  • filepath – File path of the presention to clean up after
  • clean_for_update – Only clean thumbnails if update is needed
Returns:

None

find_controller_by_type(filename)[source]

Determine the default application controller to use for the selected file type. This is used if “Automatic” is set as the preferred controller. Find the first (alphabetic) enabled controller which “supports” the extension. If none found, then look for a controller which “also supports” it instead.

Parameters:filename – The file name
generate_slide_data(service_item, item=None, xml_version=False, remote=False, context=2, presentation_file=None)[source]

Generate the slide data. Needs to be implemented by the plugin.

Parameters:
  • service_item – The service item to be built on
  • item – The Song item to be used
  • xml_version – The xml version (not used)
  • remote – Triggered from remote
  • context – Why is it being generated
initialise()[source]

Populate the media manager tab

load_list(files, target_group=None, initial_load=False)[source]

Add presentations into the media manager. This is called both on initial load of the plugin to populate with existing files, and when the user adds new files via the media manager.

on_delete_click()[source]

Remove a presentation item from the list.

populate_display_types()[source]

Load the combobox with the enabled presentation controllers, allowing user to select a specific app if settings allow.

presentations_add_to_service
presentations_go_live
required_icons()[source]

Set which icons the media manager tab should show.

retranslateUi()[source]

The name of the plugin media displayed in UI

search(string, show_error)[source]

Search in files

Parameters:
  • string – name to be found
  • show_error – not used
Returns:

setup_item()[source]

Do some additional setup.