-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
Force video player in flash mode. #3195
Conversation
* it returns `false` | ||
*/ | ||
function isHtml5Mode() { | ||
return this.getPlayerMode() === 'html5'; |
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.
why not isMode(mode_name)?
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.
By using current helpers you shouldn't remember possible values for the player mode.
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.
Makes sense.
Am I right, that there is no way to use this code to force flash mode in manual tests? |
Just set the cookie. |
I will try then) |
Works fine manually. |
@valera-rozuvan please review. |
@@ -234,6 +234,7 @@ function (Sjson, AsyncProcess) { | |||
}; | |||
} | |||
|
|||
this.el.removeClass('is-captions-rendered'); |
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.
@polesye Please write a comment what is being hidden here, and why. Is it the entire transcripts panel?
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.
Nothing is being hidden. Just a class that provides us some information about video player.
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.
@polesye I didn't know this. When I look at the code in two month, I will now know why we are doing this. Please write a comment what information is provided and where it is used. For example do we use this in tests?
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.
I think the name speaks for itself. Yes, it is.
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.
@polesye Do you mind if I add a comment for this line of code, and commit?
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.
Up to you
@polesye I have tried running this branch locally in Chrome, and I get the following JavaScript error:
|
I think it's because latest rebase with conflicts. I'll fix it. |
Try it now. |
@polesye The error
is not present any longer. Cool. |
@polesye I have added a comment. Please see 266ce6ebefb655a7f8c7afff6dbb0cb8d0bdf844 commit. |
@polesye I have checked locally. Video player works as expected in Firefox (Flash, and HTML5 modes), and in Chrome. Code looks good. 👍 Good to merge! |
@polesye Removed my commit 266ce6ebefb655a7f8c7afff6dbb0cb8d0bdf844 from this PR. Sorry for the troubles! = ) |
@polesye Please squash commits before merging. |
Force video player in flash mode.
Ticket: BLD-958
Solution: add cookie
edX_video_player_mode
withflash
value to force video player in flash mode.@auraz , @valera-rozuvan please review.