-
Notifications
You must be signed in to change notification settings - Fork 867
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stay in fullscreen/fullwindow/PiP + default viewing mode setting #5903
base: development
Are you sure you want to change the base?
Stay in fullscreen/fullwindow/PiP + default viewing mode setting #5903
Conversation
Current limitations: does not work for the search bar, randomly encountered YT video links (e.g., in descriptions), or the video thumbnail link in the playlist list view.
…l player is set This will prevent issues with users who accidentally change this setting and report that clicking on videos results in errors.
…Container element
Theatre mode is not mutually exclusive with the viewing mode and thus should not be included here. This also saves us the work of having to update the default viewing mode to theatre mode on first load for 1-2 releases that we would have otherwise needed.
fcb1cfb
to
937935f
Compare
VirtualBoxVM_M1Tz4qFemr.mp4
|
See my thoughts on that here:
Also, good catch on that bug! Will look into that. Funnily enough, I think we actually have a feature request for something like this, but not as buggy looking I'd imagine, and not implemented by accident lol
Not directly, since this PR only affects the behavior immediately following the countdown, but it would be good to have that UX issue resolved (separate PR though for sure) |
<component | ||
:is="watchPageLinkType" | ||
class="thumbnailLink" | ||
tabindex="-1" | ||
:to="watchPageLinkTo" | ||
href="javascript:void(0)" | ||
@click="handleWatchPageLinkClick" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As this code is quite confusing to read, it would probably be better to use a v-if
and v-else
here and for the second instance of the same thing below.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it, is there a way I can do this without duplicating the children for the v-else case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update: I cleaned this up in bb3be09
@kommunarr That bug is caused by not entering full window correctly, you just set the property to true but don't scroll to the top or add the CSS class that disables scrolling. Please make sure the features in this pull request behave exactly the same as the buttons and keyboard shortcuts do (that's what I meant by please don't reinvent the wheel in the private messages): https://github.com/FreeTubeApp/FreeTube/blob/development/src/renderer/components/ft-shaka-video-player/ft-shaka-video-player.js#L1649-L1661 |
Hmm presenting my arguments for why i think it should be included in the dropdown.
To me as an user it isnt clear to me at all what will be my default viewing mode, is it fullscreen or theater? |
@efb4f5ff-1298-471a-8973-3d47447115dc I don't have much to say other than that your points are valid and it's a tradeoff either way. 937935f is the commit to drop if we want to put Theater Mode in there. I'm still leaning towards keeping them separate, but I am open to hearing more perspectives as well. |
Just about "Default Viewing Mode" now has
|
I was thinking about the same thing you were Pika, but I ultimately think we're overthinking it because we are assuming that people will inherently be asking themselves "but how does theater mode play into it" and get confused, when I don't think there is any inherent reason to do that or imply it if our settings structure doesn't. If we have it as separate settings, that's an intuitive indication that viewing mode is orthogonal to whether theater mode is enabled, which is in fact the case in reality as well. For Fullwindow or Fullscreen, you have to actually exit that viewing mode to interact with things like comments and seeing the playlist / recommended videos, and you'll have to see a player that is in theater mode or isn't. If you're in PiP, the size of the grayed out video player is still in play if you want to toggle it off, and that video player is in theater mode or isn't. I think we might be assuming that it is going to be a comprehension problem when we theorize it out in terms of number of total distinct states, but I believe that the UX of them being separate settings altogether makes the relationship much less complex and far more intuitive than we're making it out to be. |
I simply find having 2 "default" a bit confusing Also can you add some new lines for long paragraphs :S |
7431c01
to
bb3be09
Compare
One case I haven't implemented: staying in PiP when you click another video without letting it autoplay. It's a bit specific, but I am thinking about it. |
As PiP and full screen by default are only supported in Electron, please make sure that those options are hidden in the UI outside of Electron (the screenshot settings are like that so you can take inspiration for how it is handled there) and that if the user does have those values set (e.g. copying the settings.db from FreeTube desktop to FreeTubeAndroid) that it acts as if the settings are not set, so that it doesn't break anything. |
…en Electron is not available
This allows staying in PiP when clicking on other videos, staying in fullscreen/fullwindow when using Ctrl+Left Arrow / Ctrl+Right Arrow, and staying in PiP when using the watch-video-playlist Play Prev / Play Next buttons.
…at/preferred-viewing-mode
Updated logic to have the reincarnate-with player state variables saved on player destroy instead of video ended, thus allowing staying in PiP when clicking on an arbitrary video, staying in fullscreen/fullwindow when using Ctrl+Left Arrow / Ctrl+Right Arrow, and staying in PiP when using the watch-video-playlist Play Prev / Play Next buttons. Also updated the settings dropdown to check |
@@ -928,6 +928,14 @@ function runApp() { | |||
return app.getPath('pictures') | |||
}) | |||
|
|||
ipcMain.on(IpcChannels.REQUEST_FULLSCREEN, ({ sender }) => { | |||
sender.executeJavaScript('document.getElementById("videoContainer").requestFullscreen({navigationUI: "hide"})', true) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Question: why is this required? (ipcRenderer.send(IpcChannels.REQUEST_FULLSCREEN)
then this
Stay in fullscreen/fullwindow/PiP + default viewing mode setting
Pull Request Type
Related issue
closes #5427
#2295
Description
Default Viewing Mode
dropdown setting for whether to enable fullscreen / fullwindow / PiP / external player by default (i.e., the same way thatEnable Theater Mode by Default
works)External Player
option corresponds specifically to when anft-list-video
is interacted with, not any YT links found in a description or entered into the search bar. This was not implemented because we would have to implement logic for creating the external player video config from a URL, which is somewhat marginal and not sufficiently germane to this PR.External Player
option does not appear as an option when no external player is setExternal Player
prior to this, it is de facto set toDefault
until a new external player is seten-us
:Enable Theatre Mode by Default
->Enable Theater Mode by Default
Turn on Captions by Default
->Enable Captions by Default
(for visual consistency / grouping with its compatriot)View Playback Rate Interval
input moved from the sameft-flex-box
with the sliders -> colocated with the otherft-input
s (it appeared odd visually and was not a sufficiently logical grouping)ft-input
s moved to above the flex box offt-slider
s (better logical/related grouping)Screenshots
Testing
Default
viewing mode should persist, NOT FS/FW/PiP.External Player
, clicking on anyft-list-video
will attempt to play it in the currently active external player. Anyft-list-video
should also not have a redundant External Player icon.External Player
toNone
. The viewing mode should now function asdefault
, and clicking on anyft-list-video
will play it in the Watch page normally.Enable Theater Mode by Default
enabled/disabled still works as intended.Desktop
Additional context
I combined "Stay in fullscreen/fullwindow/PiP" with "default viewing mode setting" under one PR because the latter one is actually very little code, and testing them both together is more time efficient for you all. I can separate this out if desired, although I'd imagine it would not be.