lucisgit / moodle-filter_jwplayer

Moodle (<=3.1) filter that allows using JW Player for playing HTML5 and flash content.
https://moodle.org/plugins/view/filter_jwplayer
6 stars 6 forks source link

filter_jwplayer: Change div tags to span and update css to display inline (bug #3) #24

Closed owenbarritt closed 9 years ago

owenbarritt commented 9 years ago

I've switch the inserted div tags to span, which is more consistent with the core media filters and stops the issue of the surrounding tags being closed.

Added extra css to override the css added by the player, so it displays inline within our block.

This makes the player always centered (due to the existing text-align statement in the filter css) rather than left-aligned, but at least that's consistent with the core players.

kabalin commented 9 years ago

Does it mean the player can be positioned to any side with this fix, or it will always stick to the middle?

owenbarritt commented 9 years ago

It sticks it to the middle, as that's consistent with the core media filters.

It could be changed to use the inherited alignment of the parent tags by removing the existing text-align statement in styles.css, but that would be inconsistent with the way moodle handles other media.

kabalin commented 9 years ago

I merged this, but it does not fully resolve #3, though I agree, it makes it at least consistent with how moodle handles other media.

owenbarritt commented 9 years ago

Not sure there's any way around that without becoming inconsistent with the core media filter.

The workarounds discussed here https://moodle.org/mod/forum/discuss.php?d=205102 should work though if a user wanted a different alignment.