Commit 9668a250 authored by ronald's avatar ronald

Updated contentScript.js

parent 3db277f6
......@@ -23,11 +23,8 @@ if (link.match(/login/g)){
var count;
var scroll = setInterval(function() {
var currentScrollTop = el.scrollTop;
console.log("Current Top: ", currentScrollTop);
el.scrollBy(0,5000);
var scrolledTop = el.scrollTop;
console.log("Scrolled Top: ", scrolledTop);
console.log("Scroll diff : ", scrolledTop - currentScrollTop);
if(scrolledTop - currentScrollTop == 0) {
count +=1;
} else {
......@@ -41,6 +38,11 @@ if (link.match(/login/g)){
downloadlist.forEach(function(a) {
if(a.innerText.match(/(jpg|gif)/g)) {
a.click();
if(a.innerText.match(/^G/g)) {
console.log(a.innerText.trim());
if(!a.innerText.match(/Model/g))
a.click();
}
}
document.querySelector("#assets_btn_download_asset").click();
});
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment