code-charity / youtube

[top~1 open YouTube & Video web-extension] Enrich your experience & choice! 🧰100+clever features📌set&forget📌Longest-standing(yet rare&tough alone. Please help/join🧩us👨‍👩‍👧‍👧) ..⋮ {playback|content discovery|player|extra buttons|distractions|related videos|shorts|ads|quality|codec|full tab|full screen}
http://improvedtube.com
Other
3.29k stars 498 forks source link

Update init.js removing only one instance playing kludge #2356

Closed raszpl closed 2 weeks ago

raszpl commented 2 weeks ago

fixing up after https://github.com/code-charity/youtube/commit/dc56797f195750aaf6b3e2b8028ef6dd97c7bbfb also partially fixes https://github.com/code-charity/youtube/issues/2284 message spam by only sending messages to connected tabs we have permissions for. still need to get rid or at least fix the blur/focus https://github.com/code-charity/youtube/blob/6d369c11c3a621bf1bf6cbd502cff96537671024/background.js#L162 spam mentioned in https://github.com/code-charity/youtube/pull/2299#issuecomment-2127002469

ImprovedTube commented 2 weeks ago

hi! :) what about the removed lines in background.js

https://github.com/code-charity/youtube/pull/2356/files%20%20chrome.scripting.executeScript(%7B%20target:%20%7B%20tabId:%20tID%20%7D,%20func:%20()%20=%3E%20%7B%20document.title%20=%20%60$%7Bmessage.title%7D%20-%20ImprovedTube%60;%20%7D%20%7D)//manifest3%20//%20chrome.tabs.executeScript(tID,%20%7Bcode:%20%60document.title%20=%20%22$%7Bmessage.title%7D%20-%20ImprovedTube%22;%60%7D);%20%20//manifest2

raszpl commented 2 weeks ago

link doesnt work so I dont know which ones., but as the commit messasge says remove dead code

ImprovedTube commented 2 weeks ago

greetings @MohamedLebda

ImprovedTube commented 2 weeks ago

case 'download'
and chrome.scripting.executeScript (or does chrome.tabs.executeScript still work with manifest 3?) @raszpl

raszpl commented 2 weeks ago

'download' is dead code, its not used anywhere https://github.com/search?q=repo%3Acode-charity%2Fyoutube%20download&type=code executeScript my fault, I used older version (4.938) when making the patch and didnt notice it changed after switch to manifest3.

raszpl commented 2 weeks ago

fix of your edit https://github.com/code-charity/youtube/pull/2370