您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Allows you to watch youtube videos in not distorted (scaled) 720p resolution. Click on the title of the video to redirect you.
当前为
// ==UserScript== // @name Youtube true 720p player // @description Allows you to watch youtube videos in not distorted (scaled) 720p resolution. Click on the title of the video to redirect you. // @author Jan harvalík [email protected] // @version 1.5 // @date 2015-12-05 // @require https://code.jquery.com/jquery-2.1.4.min.js // @include http://www.youtube.com/* // @include https://www.youtube.com/* // @include http://www.youtube.com/user/* // @include https://www.youtube.com/user/* // @exclude http://www.youtube.com/embed/* // @exclude https://www.youtube.com/embed/* // @grant GM_xmlhttpRequest // @grant GM_getValue // @grant GM_setValue // @run-at document-end // @license MIT License // @namespace https://greasyfork.org/users/12627 // ==/UserScript== var script = document.createElement('script'); script.src = "https://code.jquery.com/jquery-2.1.4.min.js"; document.getElementsByTagName('head')[0].appendChild(script); var lastLocation =""; window.setInterval(function(){ if(lastLocation != $(location).attr('href')){ if($('#progress').length === 0){ // progress bar exists => page is being loaded -> do nothing lastLocation=$(location).attr('href'); $( document ).ready(function() { // might be useless // for youtube.com/ and youtube.com/feed/subscriptions $(".yt-lockup-thumbnail a").each(function( index ) { $(this).attr("href", $(this).get(0).href.replace('https://www.youtube.com/watch?v=', 'http://www.googledrive.com/host/0B-gs6HL8vtTZeXd3bHhqZmIwWjg/?v=') ); $(this).attr('target','_blank'); // adds text bellow thumbnails $(this).parent().after("<h5 style=\"color:red;\">▲ Watch in true 720p player</h5>"); // arrow up }); // for youtube.com/watch $("#eow-title").before("►"); // arrow right $("#eow-title").parent().css("color", "red"); $("#eow-title ").css("cursor","pointer"); var v=$(location).attr("href").split('v=')[1]; $("#eow-title").on( "click", function() { // Pause the video if playing if($('.ytp-play-button').attr("aria-label") == "Pause"){ $('.ytp-play-button').click(); } window.open("http://www.googledrive.com/host/0B-gs6HL8vtTZeXd3bHhqZmIwWjg/?v="+v,"_blank"); }); }); } } }, 100);