Rework Youtube filter

Review Request #111522 - Created July 15, 2013 and updated

Information
Dario Freddi
ktp-text-ui
Reviewers
telepathy
davidedmundson, ddomenichelli
This patch reworks the filter plugin for youtube. Instead of using a quite weak heuristics, use oembed straight from youtube, which gives us also a couple more neat features (such as replacing the URL with the video title).

Anyway - as a suggestion, I'd give up embedding the video and use the thumbnail instead (which we now have access to).
Tested with drdanz, works

Issues

  • 2
  • 0
  • 0
  • 2
Description From Last Updated
We used to support youtu.be links. This is a regression David Edmundson David Edmundson
I can't allow synchronous calls in the text-ui. Sorry. If you open the log viewer you'll block for ages. We ... David Edmundson David Edmundson
David Edmundson

   
filters/youtube/youtube-filter.cpp (Diff revision 2)
 
 
We used to support youtu.be links. This is a regression
filters/youtube/youtube-filter.cpp (Diff revision 2)
 
 
I can't allow synchronous calls in the text-ui. Sorry. If you open the log viewer you'll block for ages. 

We do the iframe mostly to avoid the sync behaviour. Original code actually looked something like this, it was changed for a reason.

See the bugzilla plugin and copy that. That also has an async JSON query. It's not perfect, but it's way better than blocking. In many ways, I think the principle behind doing web calls in JS is nicer than the proposed design we did in Cambridge. 
Loading...