yyetslinkdisplayer

对人人影视资源下载的在线看一栏加入一键链接复制(复制人人客户端下载链接)

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         yyetslinkdisplayer
// @namespace    http://tampermonkey.net/
// @version      0.7
// @description  对人人影视资源下载的在线看一栏加入一键链接复制(复制人人客户端下载链接)
// @author       Callback
// @match        http://got002.com/*
// @grant        GM_setClipboard
// ==/UserScript==

(function() {
    'use strict'
    /*setTimeout(function(){
     $(".btn-toggle-view").click()
    },1000);
    setTimeout(function(){
     $(".btn-toggle-view").click()
    },2000);*/
    //setInterval(function(){
    /*setInterval(function(){
        //$(".tab-side >li >a").each(function(index){$(this).click()})
        $("div[id$='-APP']")
        $(".showlinks2").remove()
        $("ul.down-list[format='APP']").parent().append('<div class="showlinks2"><a class="btn btn-default rrsharer" style="transition: background-color 0.3s ease 0s; border-color: rgba(0, 0, 0, 0.35); background-color: rgb(193, 230, 198);">复制以上人人下载链接</a></div>')

        $("a.rrsharer").click(function(){
            let links = []
            //根据同胞元素找到对应的需要copy的链接
            $(this).parent().siblings("ul.down-list[format='APP']").find("a[class='btn rrdown btn-download']").each(function(){
                links.push($(this).attr('data-url'))
            })
            GM_setClipboard(links.join('\n'), 'text')
            alert('Copy Success!')
        })
    }, 500);*/
    function displaylink() {
            $("div[id$='-APP']")
            $(".showlinks2").remove()
            $("ul.down-list[format='APP']").parent().append('<div class="showlinks2"><a class="btn btn-default rrsharer" style="transition: background-color 0.3s ease 0s; border-color: rgba(0, 0, 0, 0.35); background-color: rgb(193, 230, 198);">复制以上人人下载链接</a></div>')

            $("a.rrsharer").click(function(){
                let links = []
                //根据同胞元素找到对应的需要copy的链接
                $(this).parent().siblings("ul.down-list[format='APP']").find("a[class='btn rrdown btn-download']").each(function(){
                    links.push($(this).attr('data-url'))
                })
                GM_setClipboard(links.join('\n'), 'text')
                alert('Copy Success!')
            })

    }
    //这个方法使用无效    $(document).ready(function () {

    //setTimeout(function(){
    window.onload=function(){
        displaylink();
        $(".tab-side >li >a").click(function(){
            //$(".tab-side >li >a").each(function(index){$(this).click()})
            displaylink();
        })}
    //}, 1000);

    setTimeout(function(){
        displaylink();
        $(".tab-side >li >a").click(function(){
            //$(".tab-side >li >a").each(function(index){$(this).click()})
            displaylink();
        })
    }, 3000);
})()