Skip to content

Commit

Permalink
Accidental global for specific controls fix
Browse files Browse the repository at this point in the history
Also contains fixes for targetted non media-element-js controls
  • Loading branch information
Lewiscowles1986 committed Nov 9, 2019
1 parent 86b399a commit b3348c4
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
4 changes: 2 additions & 2 deletions index.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
* Plugin Name: Media Playback Speed
* Description: Appends playback buttons to the Audio Player, Video Player & PLaylist shortcodes. Based on original by Daron Spence.
* Author: LewisCowles
* Version: 1.1.4
* Version: 1.1.5
*/

add_action( 'wp_enqueue_scripts', function() {
wp_enqueue_script(
'cd2-media-playback-speed-js',
plugins_url( 'playback-speed.js', __FILE__ ),
[],
'1.1.4',
'1.1.5',
true
);
}, 1, 100);
Expand Down
4 changes: 2 additions & 2 deletions playback-speed.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,10 @@
}

var mediaPlaybackContainer;
if(mediaTag) { mediaTag.closest('.mejs-container'); }
if(mediaTag) { mediaPlaybackContainer = mediaTag.closest('.mejs-container'); }

// This allows use outside of WordPress for this
if(!mediaPlaybackContainer) { mediaPlaybackContainer = document.body; }
if(!mediaTag || !mediaPlaybackContainer) { mediaPlaybackContainer = mediaTag || document.body; }

// Clear all active playback rate buttons for this element of the active class
[].slice.call(
Expand Down
5 changes: 4 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: frontend,media,streaming,aria,mediaelementjs,html5,video,audio,playback,sp
Requires at least: 4.0
Tested up to: 5.2.4
Requires PHP: 5.6
Stable tag: 1.1.4
Stable tag: 1.1.5
License: GPL-3.0
License URI: https://www.gnu.org/licenses/gpl-3.0.html

Expand Down Expand Up @@ -57,6 +57,9 @@ Please feel free to [suggest](https://github.com/CODESIGN2/media-playback-speed/
Download and extract the zip file or clone this repo to your WordPress plugins directory. Alternatively use the plugin directory to find and install this plugin.

== Changelog ==
= 1.1.5 =
* More Non-mediaelement JS fixes for global / local

= 1.1.4 =
* Non-mediaelement JS fixes

Expand Down

0 comments on commit b3348c4

Please sign in to comment.