videoclip 0.2.4 → 0.2.5
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/videoclip/videos/funny_or_die.rb +23 -0
- data/videoclip.gemspec +3 -2
- metadata +3 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.5
|
@@ -0,0 +1,23 @@
|
|
1
|
+
module LaserLemon
|
2
|
+
module Videoclip
|
3
|
+
class Video::FunnyOrDie < Video
|
4
|
+
def self.match?(uri)
|
5
|
+
(uri.host =~ /^(?:www\.)?funnyordie\.com$/i) && (uri.path =~ /^\/videos\/[0-9a-f]{10}\//)
|
6
|
+
end
|
7
|
+
|
8
|
+
def assign(uri)
|
9
|
+
@key = uri.path.match(/^\/videos\/([0-9a-f]{10})\//)[1]
|
10
|
+
@url = "http://www.funnyordie.com/videos/#{@key}"
|
11
|
+
end
|
12
|
+
|
13
|
+
def embed(style = nil)
|
14
|
+
%(<object width="#{width(style)}" height="#{height(style)}" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" id="ordie_player_#{@key}"><param name="movie" value="http://player.ordienetworks.com/flash/fodplayer.swf" /><param name="flashvars" value="key=#{@key}" /><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always"></param><embed width="#{width(style)}" height="#{height(style)}" flashvars="key=#{@key}" allowfullscreen="true" allowscriptaccess="always" quality="high" src="http://player.ordienetworks.com/flash/fodplayer.swf" name="ordie_player_#{@key}" type="application/x-shockwave-flash"></embed></object>)
|
15
|
+
end
|
16
|
+
|
17
|
+
protected
|
18
|
+
def chrome_height
|
19
|
+
40
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
data/videoclip.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{videoclip}
|
8
|
-
s.version = "0.2.
|
8
|
+
s.version = "0.2.5"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["laserlemon"]
|
12
|
-
s.date = %q{2009-10-
|
12
|
+
s.date = %q{2009-10-09}
|
13
13
|
s.description = %q{Save videos from popular sites alongside your ActiveRecord models}
|
14
14
|
s.email = %q{steve@laserlemon.com}
|
15
15
|
s.extra_rdoc_files = [
|
@@ -26,6 +26,7 @@ Gem::Specification.new do |s|
|
|
26
26
|
"lib/videoclip.rb",
|
27
27
|
"lib/videoclip/video.rb",
|
28
28
|
"lib/videoclip/videos/blip.rb",
|
29
|
+
"lib/videoclip/videos/funny_or_die.rb",
|
29
30
|
"lib/videoclip/videos/youtube.rb",
|
30
31
|
"test/test_helper.rb",
|
31
32
|
"test/videoclip_test.rb",
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: videoclip
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- laserlemon
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-10-
|
12
|
+
date: 2009-10-09 00:00:00 -04:00
|
13
13
|
default_executable:
|
14
14
|
dependencies: []
|
15
15
|
|
@@ -32,6 +32,7 @@ files:
|
|
32
32
|
- lib/videoclip.rb
|
33
33
|
- lib/videoclip/video.rb
|
34
34
|
- lib/videoclip/videos/blip.rb
|
35
|
+
- lib/videoclip/videos/funny_or_die.rb
|
35
36
|
- lib/videoclip/videos/youtube.rb
|
36
37
|
- test/test_helper.rb
|
37
38
|
- test/videoclip_test.rb
|