streamapi 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
data/LISENCE ADDED
@@ -0,0 +1,30 @@
1
+ New BSD License
2
+ ===============
3
+
4
+ Copyright (c) 2010, Panagiotis Papadopoulos.
5
+ All rights reserved.
6
+
7
+ Redistribution and use in source and binary forms, with or without modification,
8
+ are permitted provided that the following conditions are met:
9
+
10
+ * Redistributions of source code must retain the above copyright notice, this
11
+ list of conditions and the following disclaimer.
12
+
13
+ * Redistributions in binary form must reproduce the above copyright notice,
14
+ this list of conditions and the following disclaimer in the documentation and/or
15
+ other materials provided with the distribution.
16
+
17
+ * Neither the name of Found Line, Inc. nor the names of its contributors may be
18
+ used to endorse or promote products derived from this software without specific
19
+ prior written permission.
20
+
21
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
22
+ ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
23
+ WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
24
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
25
+ ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
26
+ (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
27
+ LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
28
+ ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
30
+ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
@@ -3,49 +3,27 @@ module StreamAPI
3
3
 
4
4
  def self.to_html(private_host_id, public_host_id, site_id, theme)
5
5
  embed_code = <<-EOF
6
- <OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
7
- codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0"
8
- width="#{theme['width']}" height="#{theme['height']}" id="liveStream" align="">
9
- <PARAM name="movie" value="http://static.streamapi.com/flash/loader.swf?app=custom.swf&1247246891974">
10
- <PARAM name="FlashVars" value="siteID=#{site_id}&publicHostID=#{public_host_id}
11
- &layoutPath=#{theme['layout_path']}
12
- &skinPath=#{theme['skin_path']}
13
- &privateHostID=#{theme['private_host_id']}&userType=host&">
14
- <PARAM name="allowScriptAccess" value="always">
15
- <PARAM name="allowFullScreen" value="true">
16
- <PARAM name="quality" value="high">
17
- <PARAM name="bgcolor" value="#000000">
18
- <PARAM name="scale" value="noscale">
19
- <PARAM name="wmode" value="transparent">
20
- <embed src="http://static.streamapi.com/flash/loader.swf?app=custom.swf&1247246891974"
21
- FlashVars="siteID=#{site_id}&publicHostID=#{public_host_id}
22
- &layoutPath=#{theme['layout_path']}
23
- &skinPath=#{theme['skin_path']}
24
- &privateHostID=#{theme['private_host_id']}&userType=host&"
25
- allowScriptAccess="always" allowFullScreen="true" width="#{theme['width']}" height="#{theme['height']}" scale="noscale"
26
- wmode="transparent" quality="high" bgcolor="#000000" type="application/x-shockwave-flash" >
27
- </embed>
28
- </OBJECT>
29
- <div id="player_container"></div>
30
-
31
- <script type="text/javascript"
32
- src="http://ajax.googleapis.com/ajax/libs/swfobject/2.1/swfobject.js"></script>
33
-
34
- <script type="text/javascript">
35
- swfobject.embedSWF("http://static.streamapi.com/flash/loader.swf", "player_container",
36
- "#{theme['width']}", "#{theme['height']}", "9", "", {
37
- 'app' : 'custom.swf',
38
- 'siteID' : '#{site_id}',
39
- 'publicHostID' : '#{public_host_id}',
40
- 'layoutPath' : '#{theme['layout_path']}',
41
- 'skinPath' : '#{theme['skin_path']}',
42
- 'privateHostID' : '#{theme['private_host_id']}',
43
- 'userType' : 'host'
44
- }, {
45
- allowfullscreen: "true",
46
- allowscriptaccess: "true"
47
- });
48
- </script type="text/javascript">
6
+ <embed
7
+ height="#{theme['height'] }"
8
+ width="#{theme['width'] }"
9
+ wmode=""
10
+ type="application/x-shockwave-flash"
11
+ bgcolor="#000000"
12
+ quality="high"
13
+ scale="noscale"
14
+ allowfullscreen="true"
15
+ allowscriptaccess="always"
16
+ flashvars=
17
+ "authField2Label=Display Name:
18
+ &authField1Label=UserName:
19
+ &siteID=#{site_id}
20
+ &layoutPath=#{theme['layout_path']}
21
+ &skinPath=#{theme['skin_path']}
22
+ &publicHostID=#{public_host_id}
23
+ &privateHostID=#{private_host_id}
24
+ &authType=key
25
+ &userType=204&"
26
+ src="http://static.streamapi.com/flash/loader.swf?app=custom.swf" />
49
27
  EOF
50
28
 
51
29
  embed_code
@@ -1,3 +1,3 @@
1
1
  module Streamapi
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 3
9
- version: 0.0.3
8
+ - 4
9
+ version: 0.0.4
10
10
  platform: ruby
11
11
  authors:
12
12
  - Panagiotis Papadoulos
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-11-05 00:00:00 +02:00
17
+ date: 2010-11-09 00:00:00 +02:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
@@ -43,6 +43,7 @@ extra_rdoc_files: []
43
43
  files:
44
44
  - .gitignore
45
45
  - Gemfile
46
+ - LISENCE
46
47
  - README.rdoc
47
48
  - Rakefile
48
49
  - lib/streamapi.rb