Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-58361

Prevent core_media_manager from being subclassed

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide
      1. Disable filter_mediaplugins
      2. Make sure video.js is your topmost media plugin
      3. Create a file resource and upload a video to it
      4. Ensure video.js works (should see the rectangular play button at first with no video controls - don't just assume any video player means it's working as it might be HTML5)
      5. Enable filter_mediaplugins
      6. Enable "Convert URLs into links and images" filter
      7. Add a link to a video file
      8. Ensure it works
      Show
      Disable filter_mediaplugins Make sure video.js is your topmost media plugin Create a file resource and upload a video to it Ensure video.js works (should see the rectangular play button at first with no video controls - don't just assume any video player means it's working as it might be HTML5) Enable filter_mediaplugins Enable "Convert URLs into links and images" filter Add a link to a video file Ensure it works
    • Affected Branches:
      MOODLE_33_STABLE
    • Fixed Branches:
      MOODLE_33_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-58361-master

      Description

      There's no reason or benefit from subclassing core_media_manager. It's a singleton so should have a private constructor. Any added functionality should be part of a media plugin.

      A third party plugin that subclasses the media manager will only affect instances created of that subclass, and will not effect current areas of code calling the media manager. The current code is misleading for plugin devs

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                johno John Okely
                Reporter:
                johno John Okely
                Peer reviewer:
                Marina Glancy
                Integrator:
                Andrew Nicols
                Tester:
                Andrew Nicols
                Participants:
                Component watchers:
                Amaia Anabitarte, Bas Brands, Carlos Escobedo, Sara Arjona (@sarjona), Víctor Déniz Falcón, Jake Dallimore, Jun Pataleta, Ryan Wyllie
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  15/May/17