Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // ==UserScript==
- // @name 4Anime Hard Subs Blocker
- // @namespace http://tampermonkey.net/
- // @version 0.1
- // @description block hard coded subtitles
- // @author 透明水晶#6554
- // @match https://*/*
- // ==/UserScript==
- (function() {
- let vid = document.getElementsByTagName("video")[0];
- let canvas = document.createElement("canvas");
- canvas.id = "paintpad";
- canvas.style.position = "absolute";
- canvas.style.top = 0;
- canvas.style.left = 0;
- canvas.style.width = "100%";
- canvas.style.height = "100%";
- canvas.styleText = "position: absolute; top: 0; left: 0; width: 100%; height: 100%;";
- vid.parentNode.insertBefore(canvas, vid.nextSibling);
- let canv = document.getElementById("paintpad");
- let ctx = canv.getContext("2d");
- ctx.fillStyle = "rgb(255,255,255)";
- ctx.fillRect(30,119,240,26);
- canv.addEventListener("click", function(){
- if (vid.paused) vid.play();
- else vid.pause()
- });
- })();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement