bivouac 0.1.4 → 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (58) hide show
  1. data/README +6 -7
  2. data/bin/bivouac +1 -1
  3. data/doc/rdoc/classes/BivouacHelpers/BaseView.html +178 -0
  4. data/doc/rdoc/classes/BivouacHelpers/FormView.html +398 -0
  5. data/doc/rdoc/classes/BivouacHelpers/HtmlView.html +305 -0
  6. data/doc/rdoc/classes/BivouacHelpers/JavaScriptView.html +573 -0
  7. data/doc/rdoc/classes/BivouacHelpers/ScriptAculoUsView.html +258 -0
  8. data/doc/rdoc/classes/BivouacHelpers/TooltipView.html +158 -0
  9. data/doc/rdoc/classes/BivouacHelpers.html +117 -0
  10. data/doc/rdoc/classes/JavaScriptGenerator.html +564 -0
  11. data/doc/rdoc/created.rid +1 -0
  12. data/doc/rdoc/files/AUTHORS.html +109 -0
  13. data/doc/rdoc/files/COPYING.html +533 -0
  14. data/doc/rdoc/files/README.html +427 -0
  15. data/doc/rdoc/files/lib/bivouac/helpers/view/goh/base_rb.html +109 -0
  16. data/doc/rdoc/files/lib/bivouac/helpers/view/goh/form_rb.html +109 -0
  17. data/doc/rdoc/files/lib/bivouac/helpers/view/goh/html_rb.html +109 -0
  18. data/doc/rdoc/files/lib/bivouac/helpers/view/goh/javascript_rb.html +113 -0
  19. data/doc/rdoc/files/lib/bivouac/helpers/view/goh/scriptaculous_rb.html +113 -0
  20. data/doc/rdoc/files/lib/bivouac/helpers/view/goh/tooltip_rb.html +109 -0
  21. data/doc/rdoc/index.html +10 -0
  22. data/doc/rdoc/permalink.gif +0 -0
  23. data/doc/rdoc/rdoc-style.css +106 -0
  24. data/doc/rdoc/rubyfr.png +0 -0
  25. data/examples/bivouac_sample/Rakefile +48 -0
  26. data/examples/bivouac_sample/app/bivouac_sample.rb +15 -7
  27. data/examples/bivouac_sample/app/controllers/index.rb +2 -2
  28. data/examples/bivouac_sample/app/controllers/sound.rb +10 -0
  29. data/examples/bivouac_sample/app/helpers/_helpers.rb +6 -3
  30. data/examples/bivouac_sample/app/views/sound.rb +16 -0
  31. data/examples/bivouac_sample/config/environment.rb +5 -2
  32. data/examples/bivouac_sample/config/postamble.rb +89 -18
  33. data/examples/bivouac_sample/public/javascripts/builder.js +12 -7
  34. data/examples/bivouac_sample/public/javascripts/controls.js +485 -355
  35. data/examples/bivouac_sample/public/javascripts/dragdrop.js +82 -52
  36. data/examples/bivouac_sample/public/javascripts/effects.js +361 -329
  37. data/examples/bivouac_sample/public/javascripts/prototype.js +2826 -1120
  38. data/examples/bivouac_sample/public/javascripts/scriptaculous.js +15 -8
  39. data/examples/bivouac_sample/public/javascripts/slider.js +40 -43
  40. data/examples/bivouac_sample/public/javascripts/sound.js +55 -0
  41. data/examples/bivouac_sample/public/javascripts/unittest.js +16 -12
  42. data/examples/bivouac_sample/public/sound/sword.mp3 +0 -0
  43. data/examples/bivouac_sample/script/console +6 -0
  44. data/examples/bivouac_sample/script/plugin +3 -0
  45. data/examples/bivouac_sample/script/server +2 -1
  46. data/examples/bivouac_sample/test/test_sound.rb +15 -0
  47. data/lib/bivouac/helpers/view/goh/sound.rb +38 -0
  48. data/lib/bivouac/template/application/helpers_goh.rb +2 -0
  49. data/lib/bivouac/template/static/builder.js +12 -7
  50. data/lib/bivouac/template/static/controls.js +485 -355
  51. data/lib/bivouac/template/static/dragdrop.js +82 -52
  52. data/lib/bivouac/template/static/effects.js +361 -329
  53. data/lib/bivouac/template/static/prototype.js +2826 -1120
  54. data/lib/bivouac/template/static/scriptaculous.js +15 -8
  55. data/lib/bivouac/template/static/slider.js +40 -43
  56. data/lib/bivouac/template/static/sound.js +55 -0
  57. data/lib/bivouac/template/static/unittest.js +16 -12
  58. metadata +45 -2
data/README CHANGED
@@ -1,6 +1,6 @@
1
1
  = Bivouac
2
2
 
3
- Copyright (C) 2007 Gregoire Lejeune
3
+ Copyright (C) 2007, 2008 Gregoire Lejeune
4
4
 
5
5
  * http://bivouac.rubyforge.org/
6
6
  * http://rubyforge.org/projects/bivouac/
@@ -12,6 +12,11 @@ Bivouac is a simple generator for camping[http://code.whytheluckystiff.net/campi
12
12
 
13
13
  == FEATURES/PROBLEMS:
14
14
 
15
+ === 0.1.5:
16
+ * Upgrade prototype (1.6.0.2)
17
+ * Upgrade Script.aculo.us (1.8.1)
18
+ * Add sound helper
19
+
15
20
  === 0.1.4:
16
21
  * Add Thin (http://code.macournoyer.com/thin/) support -- Thin is now the default Webserver
17
22
  * class Public modified to support thin :
@@ -107,12 +112,6 @@ Bivouac is a simple generator for camping[http://code.whytheluckystiff.net/campi
107
112
  Specific options:
108
113
  -P, --port PORT Which port to bind to (3301)
109
114
  -a, --address ADDR Address to bind to (0.0.0.0)
110
- -o, --organize TYPE Type or organisation
111
- (options: JOF:Just On File
112
- GOH:Get Out of Hand
113
- ERB:use Eruby or Erb)
114
- -p, --postamble TYPE Add a postamble
115
- (options: CGI/FastCGI/Mongrel/WEBrick/none)
116
115
 
117
116
  Common options:
118
117
  -?, --help Show this message
data/bin/bivouac CHANGED
@@ -155,7 +155,7 @@ createFile( "#{@conf.appdir}/Rakefile", true ) { |io|
155
155
 
156
156
  copyTemplate( "static/index.html", "#{@conf.appdir}/public" )
157
157
  copyTemplate( "static/camping.png", "#{@conf.appdir}/public/images" )
158
- %w{builder.js dragdrop.js prototype.js slider.js unittest.js controls.js effects.js scriptaculous.js tooltip.js}.each do |f|
158
+ %w{builder.js dragdrop.js prototype.js slider.js unittest.js controls.js effects.js sound.js scriptaculous.js tooltip.js}.each do |f|
159
159
  copyTemplate( "static/#{f}", "#{@conf.appdir}/public/javascripts" )
160
160
  end
161
161
  copyTemplate( "static/autocomplete.css", "#{@conf.appdir}/public/stylesheets" )
@@ -0,0 +1,178 @@
1
+
2
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
3
+ <html>
4
+ <head>
5
+ <title>
6
+ Bivouac, the Documentation &raquo; Module: BivouacHelpers::BaseView
7
+ </title>
8
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
9
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
10
+ <script language="JavaScript" type="text/javascript">
11
+ // <![CDATA[
12
+
13
+ function toggleSource( id )
14
+ {
15
+ var elem
16
+ var link
17
+
18
+ if( document.getElementById )
19
+ {
20
+ elem = document.getElementById( id )
21
+ link = document.getElementById( "l_" + id )
22
+ }
23
+ else if ( document.all )
24
+ {
25
+ elem = eval( "document.all." + id )
26
+ link = eval( "document.all.l_" + id )
27
+ }
28
+ else
29
+ return false;
30
+
31
+ if( elem.style.display == "block" )
32
+ {
33
+ elem.style.display = "none"
34
+ link.innerHTML = "show source"
35
+ }
36
+ else
37
+ {
38
+ elem.style.display = "block"
39
+ link.innerHTML = "hide source"
40
+ }
41
+ }
42
+
43
+ function openCode( url )
44
+ {
45
+ window.open( url, "SOURCE_CODE", "width=400,height=400,scrollbars=yes" )
46
+ }
47
+ // ]]>
48
+ </script>
49
+ </head>
50
+ <body>
51
+ <!--
52
+ <div id="menu">
53
+ <h3 class="title">Module: BivouacHelpers::BaseView</h3>
54
+ </div>
55
+ -->
56
+ <div id="fullpage">
57
+ <div id="pager">
58
+ <table>
59
+ <tr><td><img src="../../rubyfr.png" /></td>
60
+ <td id="pagertd">
61
+ <strong># Module: BivouacHelpers::BaseView<br />
62
+ [
63
+ "<a href="../../files/README.html" value="File: README">README</a>",
64
+ "<a href="../../files/AUTHORS.html" value="File: AUTHORS">AUTHORS</a>",
65
+ "<a href="../../files/COPYING.html" value="File: COPYING">COPYING</a>",
66
+ "<a href="../../files/lib/bivouac/helpers/view/goh/base_rb.html" value="File: base.rb">lib/bivouac/helpers/view/goh/base.rb</a>",
67
+ "<a href="../../files/lib/bivouac/helpers/view/goh/form_rb.html" value="File: form.rb">lib/bivouac/helpers/view/goh/form.rb</a>",
68
+ "<a href="../../files/lib/bivouac/helpers/view/goh/html_rb.html" value="File: html.rb">lib/bivouac/helpers/view/goh/html.rb</a>",
69
+ "<a href="../../files/lib/bivouac/helpers/view/goh/tooltip_rb.html" value="File: tooltip.rb">lib/bivouac/helpers/view/goh/tooltip.rb</a>",
70
+ "<a href="../../files/lib/bivouac/helpers/view/goh/scriptaculous_rb.html" value="File: scriptaculous.rb">lib/bivouac/helpers/view/goh/scriptaculous.rb</a>",
71
+ "<a href="../../files/lib/bivouac/helpers/view/goh/javascript_rb.html" value="File: javascript.rb">lib/bivouac/helpers/view/goh/javascript.rb</a>",
72
+ <a href="http://greg.rubyfr.net">nil</a>].each do<br />
73
+ <a href="../../classes/JavaScriptGenerator.html" title="Class: JavaScriptGenerator">JavaScriptGenerator</a>.view_html<br />
74
+ <a href="../../classes/BivouacHelpers.html" title="Module: BivouacHelpers">BivouacHelpers</a>.view_html<br />
75
+ <a href="../../classes/BivouacHelpers/TooltipView.html" title="Module: BivouacHelpers::TooltipView">BivouacHelpers::TooltipView</a>.view_html<br />
76
+ <a href="../../classes/BivouacHelpers/ScriptAculoUsView.html" title="Module: BivouacHelpers::ScriptAculoUsView">BivouacHelpers::ScriptAculoUsView</a>.view_html<br />
77
+ <a href="../../classes/BivouacHelpers/BaseView.html" title="Module: BivouacHelpers::BaseView">BivouacHelpers::BaseView</a>.view_html<br />
78
+ <a href="../../classes/BivouacHelpers/JavaScriptView.html" title="Module: BivouacHelpers::JavaScriptView">BivouacHelpers::JavaScriptView</a>.view_html<br />
79
+ <a href="../../classes/BivouacHelpers/HtmlView.html" title="Module: BivouacHelpers::HtmlView">BivouacHelpers::HtmlView</a>.view_html<br />
80
+ <a href="../../classes/BivouacHelpers/FormView.html" title="Module: BivouacHelpers::FormView">BivouacHelpers::FormView</a>.view_html<br />
81
+ end</strong>
82
+ </td></tr>
83
+ </table>
84
+ </ul>
85
+ </div>
86
+
87
+
88
+ <div id="BivouacHelpers::BaseView" class="page_shade">
89
+ <div class="page">
90
+ <h3>Module BivouacHelpers::BaseView &lt; Object</h3>
91
+
92
+ (in files
93
+ <a href="../../files/lib/bivouac/helpers/view/goh/base_rb.html">lib/bivouac/helpers/view/goh/base.rb</a>
94
+ )
95
+
96
+ <p>
97
+ bivouac/helpers/view/html
98
+ </p>
99
+
100
+
101
+
102
+
103
+
104
+ <h2 class="ruled">Methods</h2>
105
+ <h4 class="ruled">Public Instance method:
106
+ <strong><a name="M000027">partial( partial, options = {} )</a></strong> <a href="#M000027"><img src="../../permalink.gif" border="0" title="Permalink to Public Instance method: partial" /></a></h4>
107
+
108
+ <p>
109
+ Alias for <a href="BaseView.html#M000026">render</a>
110
+ </p>
111
+
112
+ <h4 class="ruled">Public Instance method:
113
+ <strong><a name="M000028">public_to_str( file )</a></strong> <a href="#M000028"><img src="../../permalink.gif" border="0" title="Permalink to Public Instance method: public_to_str" /></a></h4>
114
+
115
+ <p>
116
+ Return the content of a public file as string
117
+ </p>
118
+ <pre>
119
+ public_to_str( &quot;/stylesheets/autocomplete.css&quot; )
120
+ #=&gt; &quot;div.autocomplete {\n position:absolute;\n...&quot;
121
+ </pre>
122
+
123
+ <div class="sourcecode">
124
+ <p class="source-link">[ <a href="javascript:toggleSource('M000028_source')" id="l_M000028_source">show source</a> ]</p>
125
+ <div id="M000028_source" class="dyn-source">
126
+ <pre>
127
+ <span class="ruby-comment cmt"># File lib/bivouac/helpers/view/goh/base.rb, line 22</span>
128
+ 22: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">public_to_str</span>( <span class="ruby-identifier">file</span> )
129
+ 23: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">file</span>.<span class="ruby-identifier">include?</span> <span class="ruby-value str">&quot;..&quot;</span>
130
+ 24: <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">nil</span>
131
+ 25: <span class="ruby-keyword kw">end</span>
132
+ 26:
133
+ 27: <span class="ruby-identifier">file</span> = <span class="ruby-constant">ENV</span>[<span class="ruby-value str">'BIVOUAC_ROOT'</span>] <span class="ruby-operator">+</span> <span class="ruby-value str">&quot;/public/&quot;</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">file</span>
134
+ 28: <span class="ruby-identifier">open</span>( <span class="ruby-identifier">file</span> ) <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span>
135
+ 29: <span class="ruby-identifier">data</span> = <span class="ruby-identifier">f</span>.<span class="ruby-identifier">read</span>
136
+ 30: <span class="ruby-keyword kw">end</span>
137
+ 31:
138
+ 32: <span class="ruby-keyword kw">return</span> <span class="ruby-identifier">data</span>
139
+ 33: <span class="ruby-keyword kw">end</span>
140
+ </pre>
141
+ </div>
142
+ </div>
143
+ <h4 class="ruled">Public Instance method:
144
+ <strong><a name="M000026">render( partial, options = {} )</a></strong> <a href="#M000026"><img src="../../permalink.gif" border="0" title="Permalink to Public Instance method: render" /></a></h4>
145
+
146
+ <pre>
147
+ render( :hello, :object =&gt; @my_object )
148
+ </pre>
149
+ <p>
150
+ is equivalent to
151
+ </p>
152
+ <pre>
153
+ @object = @my_object
154
+ hello( )
155
+ </pre>
156
+
157
+ <div class="sourcecode">
158
+ <p class="source-link">[ <a href="javascript:toggleSource('M000026_source')" id="l_M000026_source">show source</a> ]</p>
159
+ <div id="M000026_source" class="dyn-source">
160
+ <pre>
161
+ <span class="ruby-comment cmt"># File lib/bivouac/helpers/view/goh/base.rb, line 9</span>
162
+ 9: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">render</span>( <span class="ruby-identifier">partial</span>, <span class="ruby-identifier">options</span> = {} )
163
+ 10: <span class="ruby-identifier">options</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">k</span>, <span class="ruby-identifier">v</span><span class="ruby-operator">|</span>
164
+ 11: <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">instance_variable_set</span>( <span class="ruby-node">&quot;@#{k.to_s}&quot;</span>.<span class="ruby-identifier">to_sym</span>, <span class="ruby-identifier">v</span> )
165
+ 12: <span class="ruby-keyword kw">end</span>
166
+ 13: <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">send</span>( <span class="ruby-identifier">partial</span>.<span class="ruby-identifier">to_sym</span> )
167
+ 14: <span class="ruby-keyword kw">end</span>
168
+ </pre>
169
+ </div>
170
+ </div>
171
+
172
+ </div>
173
+ </div>
174
+
175
+
176
+ </div>
177
+ </body>
178
+ </html>