<commit_before>//Copy this plugin and add 'fasterslower' to the features array. Also write the CSS :)
// Thanks:) https://gist.github.com/rocky-jaiswal/4995622
// 9/8/16 modified fasterslower UI elements

(function($) {

    $.extend(mejs.MepDefaults, {
        fasterslowerText: 'Faster/Slower'
    });

    $.extend(MediaElementPlayer.prototype, {
        speedOptions: [1, 1.25, 1.5, 2, 0.5, 0.75],
        speedOptionsText: ["1X", "1.25X", "1.5X", "2X", "0.5X", "0.75X"],
        speedOptionsIndex: 0,

        buildfasterslower: function(player, controls, layers, media) {
            var t = this;

            var displaySpeed =
                $('<div class="display-playback-speed hidden">1X</div> ')
                    .appendTo(controls)
                    .click(function(e) {
                        media.pause();
                        t.speedOptionsIndex ++;
                        media.playbackRate = t.speedOptions[t.speedOptionsIndex];
                        displaySpeed.html(t.speedOptionsText[t.speedOptionsIndex]);
                        if (t.speedOptionsIndex === 5) { t.speedOptionsIndex = -1 }
                        media.play();
                        return false;
                    });
        }
    });

})(mejs.$);
<commit_msg>Prevent autoplay on playback speed adjustment<commit_after>//Copy this plugin and add 'fasterslower' to the features array. Also write the CSS :)
// Thanks:) https://gist.github.com/rocky-jaiswal/4995622
// 9/8/16 modified fasterslower UI elements

(function($) {

    $.extend(mejs.MepDefaults, {
        fasterslowerText: 'Faster/Slower'
    });

    $.extend(MediaElementPlayer.prototype, {
        speedOptions: [1, 1.25, 1.5, 2, 0.5, 0.75],
        speedOptionsText: ["1X", "1.25X", "1.5X", "2X", "0.5X", "0.75X"],
        speedOptionsIndex: 0,

        buildfasterslower: function(player, controls, layers, media) {
            var t = this;

            var displaySpeed =
                $('<div class="display-playback-speed hidden">1X</div> ')
                    .appendTo(controls)
                    .click(function(e) {
                        t.speedOptionsIndex ++;
                        media.playbackRate = t.speedOptions[t.speedOptionsIndex];
                        displaySpeed.html(t.speedOptionsText[t.speedOptionsIndex]);
                        if (t.speedOptionsIndex === 5) { t.speedOptionsIndex = -1 }
                        return false;
                    });
        }
    });

})(mejs.$);

{'fraction_non_alphanumeric': 0.13776531838205847, 'fraction_numerical': 0.031237484981978373, 'mean_word_length': 1.751101321585903, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7651543', 'n_tokens_mistral': 785, 'n_tokens_neox': 714, 'n_words': 145}