WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 6 years ago

#29916 closed enhancement (worksforme)

Plugins cannot access existing mediaelement instances

Reported by: michael.heuberger Owned by:
Milestone: Priority: normal
Severity: normal Version: 4.0
Component: Media Keywords:
Focuses: Cc:

Description

In my plugin I'd like to call some functions on existing mediaelement.js instances. Currently there is no way to do this except creating new ones with new MediaElementPlayer() but that would eat memory and mess up with the event listeners.

Aim is to call pause(), play() and addEventListener() on the video element.

Any clues? Looks like this is either a call for an enhancement or I am missing something.

Change History (2)

#2 @wonderboymusic
6 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to worksforme
  • Status changed from new to closed

window.mejs.players contains all of the current instances

Note: See TracTickets for help on using tickets.