Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fixing PiP / Auto PiP #2457

Merged
merged 16 commits into from
Jul 7, 2024
Merged

fixing PiP / Auto PiP #2457

merged 16 commits into from
Jul 7, 2024

Conversation

raszpl
Copy link
Contributor

@raszpl raszpl commented Jul 7, 2024

  1. satus.components.select dispatches 'render' Event on component.render, fixes updating player_quality by triggering its on.render
  2. sections can be functions was breaking modals, make exception
  3. modal 'content' can be a function
  4. satus.indexOf was always broken
  5. satus.getProperty was always broken
  6. linter cleanup
  7. removing obsolete flash detection
  • thrown in Menu player_quality fix, it wasnt showing disabled resolutions correctly

Minus ~24 linter errors, 66 -> 42 .

raszpl added 10 commits July 7, 2024 11:33
+ close Auto PIP when returning to source Tab (player_autoPip_outside)
satus.components.select dispatches 'render' Event on component.render, fixes updating player_quality by triggering its on.render

sections can be functions was breaking modals, make exception

modal 'content' can be a function

satus.indexOf was always broken

satus.getProperty was always broken
@raszpl raszpl marked this pull request as ready for review July 7, 2024 12:33
@raszpl raszpl marked this pull request as draft July 7, 2024 13:11
@raszpl raszpl marked this pull request as ready for review July 7, 2024 13:24
@ImprovedTube ImprovedTube merged commit 0143f8e into code-charity:master Jul 7, 2024
1 check passed
@raszpl raszpl deleted the patch-17 branch July 7, 2024 19:09
@raszpl
Copy link
Contributor Author

raszpl commented Jul 7, 2024

4k is the known name. "Message": "2160p - 4K"

which 4K, DCI 4K is 4096 x one of many choices, like you got 4K DCI full frame 4096 x 2160, 4K DCI Scope 4096 x 1716 etc :] Exact industry name for 16:9 3840 × 2160 as on YT is 4K UHD :) But that wasnt the reason for this change, code works only if all numerical resolution values are directly in player_quality.options with no lookup from messages.json + it makes little sense to keep it in language/messages.json translate tables, its not like 4K has different names in different languages :).
player_quality.render is no longer hardcoded (like previous one at offset 7), can dynamically define cutoff for resolutions painted red, might be handy with qualityWhenRunningOnBattery later on.

This was my favorite type of patch - fixed a bunch of things and its "+220 −218" barely changed size :). Still needs a lot of testing, as Chrome PiP is very fragile not to mention relations between different states arent really simple.

I forgot to switch it to draft when I went for a nap before pushing last changes :] #2458

ImprovedTube referenced this pull request in raszpl/tweaks4ytube Aug 3, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants