Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Run in console in an option window for an extension with tab privileges, IE "Too many tabs"
- chrome.windows.getAll({populate:true},function(windows){
- var t = 0;
- var w = 0;
- windows.forEach(function(window){
- w++;
- window.tabs.forEach(function(tab){
- //collect all of the urls here, I will just log them instead
- //console.log(tab.url); // Uncomment to have each tab URL printed in the log.
- t++;
- });
- });
- console.log("Total tabs: "+t+" in "+w+" windows");
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement