wee 0.6.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. data/ChangeLog +18 -0
  2. data/doc/rdoc/classes/Enumerable.html +6 -6
  3. data/doc/rdoc/classes/Object.html +12 -12
  4. data/doc/rdoc/classes/OgScaffolder.html +53 -6
  5. data/doc/rdoc/classes/OgScaffolder/Editor.html +182 -107
  6. data/doc/rdoc/classes/String.html +12 -12
  7. data/doc/rdoc/classes/Wee/AnswerDecoration.html +9 -9
  8. data/doc/rdoc/classes/Wee/Application.html +42 -42
  9. data/doc/rdoc/classes/Wee/Brush.html +18 -18
  10. data/doc/rdoc/classes/Wee/Brush/AnchorTag.html +7 -7
  11. data/doc/rdoc/classes/Wee/Brush/FileUploadTag.html +7 -7
  12. data/doc/rdoc/classes/Wee/Brush/FormTag.html +14 -14
  13. data/doc/rdoc/classes/Wee/Brush/GenericEncodedTextBrush.html +12 -12
  14. data/doc/rdoc/classes/Wee/Brush/GenericSingleTagBrush.html +6 -6
  15. data/doc/rdoc/classes/Wee/Brush/GenericTagBrush.html +84 -84
  16. data/doc/rdoc/classes/Wee/Brush/GenericTextBrush.html +12 -12
  17. data/doc/rdoc/classes/Wee/Brush/ImageButtonTag.html +15 -15
  18. data/doc/rdoc/classes/Wee/Brush/ImageTag.html +18 -18
  19. data/doc/rdoc/classes/Wee/Brush/InputTag.html +12 -12
  20. data/doc/rdoc/classes/Wee/Brush/JavascriptTag.html +6 -6
  21. data/doc/rdoc/classes/Wee/Brush/Page.html +14 -14
  22. data/doc/rdoc/classes/Wee/Brush/SelectListTag.html +31 -23
  23. data/doc/rdoc/classes/Wee/Brush/SelectListTag/SelectListCallback.html +11 -7
  24. data/doc/rdoc/classes/Wee/Brush/SelectOptionTag.html +6 -6
  25. data/doc/rdoc/classes/Wee/Brush/SubmitButtonTag.html +7 -7
  26. data/doc/rdoc/classes/Wee/Brush/TableDataTag.html +14 -14
  27. data/doc/rdoc/classes/Wee/Brush/TableHeaderTag.html +7 -7
  28. data/doc/rdoc/classes/Wee/Brush/TableRowTag.html +36 -36
  29. data/doc/rdoc/classes/Wee/Brush/TableTag.html +6 -6
  30. data/doc/rdoc/classes/Wee/Brush/TextAreaTag.html +12 -12
  31. data/doc/rdoc/classes/Wee/Brush/TextInputTag.html +7 -7
  32. data/doc/rdoc/classes/Wee/CallbackRegistry.html +36 -36
  33. data/doc/rdoc/classes/Wee/CallbackStream.html +18 -18
  34. data/doc/rdoc/classes/Wee/Canvas.html +24 -24
  35. data/doc/rdoc/classes/Wee/Component.html +124 -124
  36. data/doc/rdoc/classes/Wee/Component/OnAnswer.html +6 -6
  37. data/doc/rdoc/classes/Wee/Decoration.html +40 -40
  38. data/doc/rdoc/classes/Wee/Delegate.html +27 -27
  39. data/doc/rdoc/classes/Wee/ErrorResponse.html +12 -12
  40. data/doc/rdoc/classes/Wee/FormDecoration.html +6 -6
  41. data/doc/rdoc/classes/Wee/GenericResponse.html +6 -6
  42. data/doc/rdoc/classes/Wee/HtmlCanvas.html +214 -214
  43. data/doc/rdoc/classes/Wee/HtmlWriter.html +40 -40
  44. data/doc/rdoc/classes/Wee/LiteralMethodCallback.html +12 -12
  45. data/doc/rdoc/classes/Wee/Md5IdGenerator.html +12 -12
  46. data/doc/rdoc/classes/Wee/MessageBox.html +12 -12
  47. data/doc/rdoc/classes/Wee/PageDecoration.html +18 -18
  48. data/doc/rdoc/classes/Wee/PagelessApplication.html +6 -6
  49. data/doc/rdoc/classes/Wee/PagelessRequest.html +12 -12
  50. data/doc/rdoc/classes/Wee/PagelessSession.html +24 -24
  51. data/doc/rdoc/classes/Wee/Presenter.html +85 -85
  52. data/doc/rdoc/classes/Wee/RedirectResponse.html +6 -6
  53. data/doc/rdoc/classes/Wee/RefreshResponse.html +6 -6
  54. data/doc/rdoc/classes/Wee/Request.html +30 -30
  55. data/doc/rdoc/classes/Wee/RequestHandler.html +31 -31
  56. data/doc/rdoc/classes/Wee/Response.html +36 -36
  57. data/doc/rdoc/classes/Wee/Session.html +104 -104
  58. data/doc/rdoc/classes/Wee/SimpleIdGenerator.html +12 -12
  59. data/doc/rdoc/classes/Wee/Snapshot.html +19 -19
  60. data/doc/rdoc/classes/Wee/Utils.html +19 -19
  61. data/doc/rdoc/classes/Wee/Utils/LRUCache.html +6 -6
  62. data/doc/rdoc/classes/Wee/ValueHolder.html +18 -18
  63. data/doc/rdoc/classes/Wee/WEBrickAdaptor.html +46 -46
  64. data/doc/rdoc/classes/Wee/WrapperDecoration.html +6 -6
  65. data/doc/rdoc/created.rid +1 -1
  66. data/doc/rdoc/files/README.html +5 -5
  67. data/doc/rdoc/files/lib/wee/core_rb.html +3 -3
  68. data/doc/rdoc/files/lib/wee/databases/og/scaffolder_rb.html +8 -1
  69. data/doc/rdoc/files/lib/wee/renderer/html/brushes_rb.html +1 -1
  70. data/doc/rdoc/fr_method_index.html +268 -264
  71. data/lib/wee.rb +1 -1
  72. data/lib/wee/databases/og/scaffolder.rb +62 -17
  73. data/lib/wee/renderer/html/brushes.rb +17 -5
  74. metadata +21 -21
@@ -86,8 +86,8 @@
86
86
  <h3 class="section-bar">Methods</h3>
87
87
 
88
88
  <div class="name-list">
89
- <a href="#M000147">new</a>&nbsp;&nbsp;
90
- <a href="#M000148">with</a>&nbsp;&nbsp;
89
+ <a href="#M000151">new</a>&nbsp;&nbsp;
90
+ <a href="#M000152">with</a>&nbsp;&nbsp;
91
91
  </div>
92
92
  </div>
93
93
 
@@ -109,19 +109,19 @@
109
109
  <div id="methods">
110
110
  <h3 class="section-bar">Public Class methods</h3>
111
111
 
112
- <div id="method-M000147" class="method-detail">
113
- <a name="M000147"></a>
112
+ <div id="method-M000151" class="method-detail">
113
+ <a name="M000151"></a>
114
114
 
115
115
  <div class="method-heading">
116
- <a href="#M000147" class="method-signature">
116
+ <a href="#M000151" class="method-signature">
117
117
  <span class="method-name">new</span><span class="method-args">(text)</span>
118
118
  </a>
119
119
  </div>
120
120
 
121
121
  <div class="method-description">
122
122
  <p><a class="source-toggle" href="#"
123
- onclick="toggleCode('M000147-source');return false;">[Source]</a></p>
124
- <div class="method-source-code" id="M000147-source">
123
+ onclick="toggleCode('M000151-source');return false;">[Source]</a></p>
124
+ <div class="method-source-code" id="M000151-source">
125
125
  <pre>
126
126
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 23</span>
127
127
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">text</span>)
@@ -135,19 +135,19 @@
135
135
 
136
136
  <h3 class="section-bar">Public Instance methods</h3>
137
137
 
138
- <div id="method-M000148" class="method-detail">
139
- <a name="M000148"></a>
138
+ <div id="method-M000152" class="method-detail">
139
+ <a name="M000152"></a>
140
140
 
141
141
  <div class="method-heading">
142
- <a href="#M000148" class="method-signature">
142
+ <a href="#M000152" class="method-signature">
143
143
  <span class="method-name">with</span><span class="method-args">()</span>
144
144
  </a>
145
145
  </div>
146
146
 
147
147
  <div class="method-description">
148
148
  <p><a class="source-toggle" href="#"
149
- onclick="toggleCode('M000148-source');return false;">[Source]</a></p>
150
- <div class="method-source-code" id="M000148-source">
149
+ onclick="toggleCode('M000152-source');return false;">[Source]</a></p>
150
+ <div class="method-source-code" id="M000152-source">
151
151
  <pre>
152
152
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 28</span>
153
153
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">with</span>
@@ -85,7 +85,7 @@ Most browsers do not send the &quot;name&quot; key together with the value
85
85
  specified by &quot;value&quot;, only &quot;name.x&quot; and
86
86
  &quot;name.y&quot;. This conforms to the standard. But Firefox also sends
87
87
  &quot;name&quot;=&quot;value&quot;. This is why I raise an exception from
88
- the <a href="ImageButtonTag.html#M000184">value</a> method. Note that
88
+ the <a href="ImageButtonTag.html#M000188">value</a> method. Note that
89
89
  it&#8217;s neccessary to parse the passed form-fields and generate a
90
90
  &quot;name&quot; fields in the request, to make this image-button work.
91
91
  </p>
@@ -99,8 +99,8 @@ it&#8217;s neccessary to parse the passed form-fields and generate a
99
99
  <h3 class="section-bar">Methods</h3>
100
100
 
101
101
  <div class="name-list">
102
- <a href="#M000183">new</a>&nbsp;&nbsp;
103
- <a href="#M000184">value</a>&nbsp;&nbsp;
102
+ <a href="#M000187">new</a>&nbsp;&nbsp;
103
+ <a href="#M000188">value</a>&nbsp;&nbsp;
104
104
  </div>
105
105
  </div>
106
106
 
@@ -135,21 +135,21 @@ it&#8217;s neccessary to parse the passed form-fields and generate a
135
135
  <div id="methods">
136
136
  <h3 class="section-bar">Public Class methods</h3>
137
137
 
138
- <div id="method-M000183" class="method-detail">
139
- <a name="M000183"></a>
138
+ <div id="method-M000187" class="method-detail">
139
+ <a name="M000187"></a>
140
140
 
141
141
  <div class="method-heading">
142
- <a href="#M000183" class="method-signature">
142
+ <a href="#M000187" class="method-signature">
143
143
  <span class="method-name">new</span><span class="method-args">()</span>
144
144
  </a>
145
145
  </div>
146
146
 
147
147
  <div class="method-description">
148
148
  <p><a class="source-toggle" href="#"
149
- onclick="toggleCode('M000183-source');return false;">[Source]</a></p>
150
- <div class="method-source-code" id="M000183-source">
149
+ onclick="toggleCode('M000187-source');return false;">[Source]</a></p>
150
+ <div class="method-source-code" id="M000187-source">
151
151
  <pre>
152
- <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 401</span>
152
+ <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 413</span>
153
153
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>
154
154
  <span class="ruby-keyword kw">super</span>
155
155
  <span class="ruby-identifier">type</span>(<span class="ruby-value str">'image'</span>)
@@ -161,21 +161,21 @@ it&#8217;s neccessary to parse the passed form-fields and generate a
161
161
 
162
162
  <h3 class="section-bar">Public Instance methods</h3>
163
163
 
164
- <div id="method-M000184" class="method-detail">
165
- <a name="M000184"></a>
164
+ <div id="method-M000188" class="method-detail">
165
+ <a name="M000188"></a>
166
166
 
167
167
  <div class="method-heading">
168
- <a href="#M000184" class="method-signature">
168
+ <a href="#M000188" class="method-signature">
169
169
  <span class="method-name">value</span><span class="method-args">(v)</span>
170
170
  </a>
171
171
  </div>
172
172
 
173
173
  <div class="method-description">
174
174
  <p><a class="source-toggle" href="#"
175
- onclick="toggleCode('M000184-source');return false;">[Source]</a></p>
176
- <div class="method-source-code" id="M000184-source">
175
+ onclick="toggleCode('M000188-source');return false;">[Source]</a></p>
176
+ <div class="method-source-code" id="M000188-source">
177
177
  <pre>
178
- <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 408</span>
178
+ <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 420</span>
179
179
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">value</span>(<span class="ruby-identifier">v</span>)
180
180
  <span class="ruby-identifier">raise</span> <span class="ruby-value str">&quot;specified value will not be used in the request&quot;</span>
181
181
  <span class="ruby-keyword kw">end</span>
@@ -86,9 +86,9 @@
86
86
  <h3 class="section-bar">Methods</h3>
87
87
 
88
88
  <div class="name-list">
89
- <a href="#M000154">new</a>&nbsp;&nbsp;
90
- <a href="#M000153">src_for</a>&nbsp;&nbsp;
91
- <a href="#M000155">with</a>&nbsp;&nbsp;
89
+ <a href="#M000158">new</a>&nbsp;&nbsp;
90
+ <a href="#M000157">src_for</a>&nbsp;&nbsp;
91
+ <a href="#M000159">with</a>&nbsp;&nbsp;
92
92
  </div>
93
93
  </div>
94
94
 
@@ -110,19 +110,19 @@
110
110
  <div id="methods">
111
111
  <h3 class="section-bar">Public Class methods</h3>
112
112
 
113
- <div id="method-M000154" class="method-detail">
114
- <a name="M000154"></a>
113
+ <div id="method-M000158" class="method-detail">
114
+ <a name="M000158"></a>
115
115
 
116
116
  <div class="method-heading">
117
- <a href="#M000154" class="method-signature">
117
+ <a href="#M000158" class="method-signature">
118
118
  <span class="method-name">new</span><span class="method-args">()</span>
119
119
  </a>
120
120
  </div>
121
121
 
122
122
  <div class="method-description">
123
123
  <p><a class="source-toggle" href="#"
124
- onclick="toggleCode('M000154-source');return false;">[Source]</a></p>
125
- <div class="method-source-code" id="M000154-source">
124
+ onclick="toggleCode('M000158-source');return false;">[Source]</a></p>
125
+ <div class="method-source-code" id="M000158-source">
126
126
  <pre>
127
127
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 201</span>
128
128
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>
@@ -135,11 +135,11 @@
135
135
 
136
136
  <h3 class="section-bar">Public Instance methods</h3>
137
137
 
138
- <div id="method-M000153" class="method-detail">
139
- <a name="M000153"></a>
138
+ <div id="method-M000157" class="method-detail">
139
+ <a name="M000157"></a>
140
140
 
141
141
  <div class="method-heading">
142
- <a href="#M000153" class="method-signature">
142
+ <a href="#M000157" class="method-signature">
143
143
  <span class="method-name">src_for</span><span class="method-args">(prop)</span>
144
144
  </a>
145
145
  </div>
@@ -150,8 +150,8 @@ This method construct the src attribute by looking up the property from the
150
150
  current component.
151
151
  </p>
152
152
  <p><a class="source-toggle" href="#"
153
- onclick="toggleCode('M000153-source');return false;">[Source]</a></p>
154
- <div class="method-source-code" id="M000153-source">
153
+ onclick="toggleCode('M000157-source');return false;">[Source]</a></p>
154
+ <div class="method-source-code" id="M000157-source">
155
155
  <pre>
156
156
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 195</span>
157
157
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">src_for</span>(<span class="ruby-identifier">prop</span>)
@@ -164,19 +164,19 @@ current component.
164
164
  </div>
165
165
  </div>
166
166
 
167
- <div id="method-M000155" class="method-detail">
168
- <a name="M000155"></a>
167
+ <div id="method-M000159" class="method-detail">
168
+ <a name="M000159"></a>
169
169
 
170
170
  <div class="method-heading">
171
- <a href="#M000155" class="method-signature">
171
+ <a href="#M000159" class="method-signature">
172
172
  <span class="method-name">with</span><span class="method-args">()</span>
173
173
  </a>
174
174
  </div>
175
175
 
176
176
  <div class="method-description">
177
177
  <p><a class="source-toggle" href="#"
178
- onclick="toggleCode('M000155-source');return false;">[Source]</a></p>
179
- <div class="method-source-code" id="M000155-source">
178
+ onclick="toggleCode('M000159-source');return false;">[Source]</a></p>
179
+ <div class="method-source-code" id="M000159-source">
180
180
  <pre>
181
181
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 205</span>
182
182
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">with</span>
@@ -86,8 +86,8 @@
86
86
  <h3 class="section-bar">Methods</h3>
87
87
 
88
88
  <div class="name-list">
89
- <a href="#M000192">new</a>&nbsp;&nbsp;
90
- <a href="#M000193">with</a>&nbsp;&nbsp;
89
+ <a href="#M000196">new</a>&nbsp;&nbsp;
90
+ <a href="#M000197">with</a>&nbsp;&nbsp;
91
91
  </div>
92
92
  </div>
93
93
 
@@ -109,19 +109,19 @@
109
109
  <div id="methods">
110
110
  <h3 class="section-bar">Public Class methods</h3>
111
111
 
112
- <div id="method-M000192" class="method-detail">
113
- <a name="M000192"></a>
112
+ <div id="method-M000196" class="method-detail">
113
+ <a name="M000196"></a>
114
114
 
115
115
  <div class="method-heading">
116
- <a href="#M000192" class="method-signature">
116
+ <a href="#M000196" class="method-signature">
117
117
  <span class="method-name">new</span><span class="method-args">()</span>
118
118
  </a>
119
119
  </div>
120
120
 
121
121
  <div class="method-description">
122
122
  <p><a class="source-toggle" href="#"
123
- onclick="toggleCode('M000192-source');return false;">[Source]</a></p>
124
- <div class="method-source-code" id="M000192-source">
123
+ onclick="toggleCode('M000196-source');return false;">[Source]</a></p>
124
+ <div class="method-source-code" id="M000196-source">
125
125
  <pre>
126
126
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 276</span>
127
127
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>
@@ -134,19 +134,19 @@
134
134
 
135
135
  <h3 class="section-bar">Public Instance methods</h3>
136
136
 
137
- <div id="method-M000193" class="method-detail">
138
- <a name="M000193"></a>
137
+ <div id="method-M000197" class="method-detail">
138
+ <a name="M000197"></a>
139
139
 
140
140
  <div class="method-heading">
141
- <a href="#M000193" class="method-signature">
141
+ <a href="#M000197" class="method-signature">
142
142
  <span class="method-name">with</span><span class="method-args">()</span>
143
143
  </a>
144
144
  </div>
145
145
 
146
146
  <div class="method-description">
147
147
  <p><a class="source-toggle" href="#"
148
- onclick="toggleCode('M000193-source');return false;">[Source]</a></p>
149
- <div class="method-source-code" id="M000193-source">
148
+ onclick="toggleCode('M000197-source');return false;">[Source]</a></p>
149
+ <div class="method-source-code" id="M000197-source">
150
150
  <pre>
151
151
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 283</span>
152
152
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">with</span>
@@ -86,7 +86,7 @@
86
86
  <h3 class="section-bar">Methods</h3>
87
87
 
88
88
  <div class="name-list">
89
- <a href="#M000185">new</a>&nbsp;&nbsp;
89
+ <a href="#M000189">new</a>&nbsp;&nbsp;
90
90
  </div>
91
91
  </div>
92
92
 
@@ -108,19 +108,19 @@
108
108
  <div id="methods">
109
109
  <h3 class="section-bar">Public Class methods</h3>
110
110
 
111
- <div id="method-M000185" class="method-detail">
112
- <a name="M000185"></a>
111
+ <div id="method-M000189" class="method-detail">
112
+ <a name="M000189"></a>
113
113
 
114
114
  <div class="method-heading">
115
- <a href="#M000185" class="method-signature">
115
+ <a href="#M000189" class="method-signature">
116
116
  <span class="method-name">new</span><span class="method-args">()</span>
117
117
  </a>
118
118
  </div>
119
119
 
120
120
  <div class="method-description">
121
121
  <p><a class="source-toggle" href="#"
122
- onclick="toggleCode('M000185-source');return false;">[Source]</a></p>
123
- <div class="method-source-code" id="M000185-source">
122
+ onclick="toggleCode('M000189-source');return false;">[Source]</a></p>
123
+ <div class="method-source-code" id="M000189-source">
124
124
  <pre>
125
125
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 213</span>
126
126
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>
@@ -86,8 +86,8 @@
86
86
  <h3 class="section-bar">Methods</h3>
87
87
 
88
88
  <div class="name-list">
89
- <a href="#M000188">title</a>&nbsp;&nbsp;
90
- <a href="#M000189">with</a>&nbsp;&nbsp;
89
+ <a href="#M000192">title</a>&nbsp;&nbsp;
90
+ <a href="#M000193">with</a>&nbsp;&nbsp;
91
91
  </div>
92
92
  </div>
93
93
 
@@ -109,21 +109,21 @@
109
109
  <div id="methods">
110
110
  <h3 class="section-bar">Public Instance methods</h3>
111
111
 
112
- <div id="method-M000188" class="method-detail">
113
- <a name="M000188"></a>
112
+ <div id="method-M000192" class="method-detail">
113
+ <a name="M000192"></a>
114
114
 
115
115
  <div class="method-heading">
116
- <a href="#M000188" class="method-signature">
116
+ <a href="#M000192" class="method-signature">
117
117
  <span class="method-name">title</span><span class="method-args">(t)</span>
118
118
  </a>
119
119
  </div>
120
120
 
121
121
  <div class="method-description">
122
122
  <p><a class="source-toggle" href="#"
123
- onclick="toggleCode('M000188-source');return false;">[Source]</a></p>
124
- <div class="method-source-code" id="M000188-source">
123
+ onclick="toggleCode('M000192-source');return false;">[Source]</a></p>
124
+ <div class="method-source-code" id="M000192-source">
125
125
  <pre>
126
- <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 467</span>
126
+ <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 479</span>
127
127
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">title</span>(<span class="ruby-identifier">t</span>)
128
128
  <span class="ruby-ivar">@title</span> = <span class="ruby-identifier">t</span>
129
129
  <span class="ruby-keyword kw">self</span>
@@ -133,21 +133,21 @@
133
133
  </div>
134
134
  </div>
135
135
 
136
- <div id="method-M000189" class="method-detail">
137
- <a name="M000189"></a>
136
+ <div id="method-M000193" class="method-detail">
137
+ <a name="M000193"></a>
138
138
 
139
139
  <div class="method-heading">
140
- <a href="#M000189" class="method-signature">
140
+ <a href="#M000193" class="method-signature">
141
141
  <span class="method-name">with</span><span class="method-args">(text=nil, &amp;block)</span>
142
142
  </a>
143
143
  </div>
144
144
 
145
145
  <div class="method-description">
146
146
  <p><a class="source-toggle" href="#"
147
- onclick="toggleCode('M000189-source');return false;">[Source]</a></p>
148
- <div class="method-source-code" id="M000189-source">
147
+ onclick="toggleCode('M000193-source');return false;">[Source]</a></p>
148
+ <div class="method-source-code" id="M000193-source">
149
149
  <pre>
150
- <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 472</span>
150
+ <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 484</span>
151
151
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">with</span>(<span class="ruby-identifier">text</span>=<span class="ruby-keyword kw">nil</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
152
152
  <span class="ruby-identifier">doc</span> = <span class="ruby-ivar">@canvas</span>.<span class="ruby-identifier">document</span>
153
153
  <span class="ruby-identifier">doc</span>.<span class="ruby-identifier">start_tag</span>(<span class="ruby-value str">&quot;html&quot;</span>)
@@ -86,9 +86,9 @@
86
86
  <h3 class="section-bar">Methods</h3>
87
87
 
88
88
  <div class="name-list">
89
- <a href="#M000163">callback</a>&nbsp;&nbsp;
90
- <a href="#M000162">new</a>&nbsp;&nbsp;
91
- <a href="#M000164">with</a>&nbsp;&nbsp;
89
+ <a href="#M000167">callback</a>&nbsp;&nbsp;
90
+ <a href="#M000166">new</a>&nbsp;&nbsp;
91
+ <a href="#M000168">with</a>&nbsp;&nbsp;
92
92
  </div>
93
93
  </div>
94
94
 
@@ -116,19 +116,19 @@
116
116
  <div id="methods">
117
117
  <h3 class="section-bar">Public Class methods</h3>
118
118
 
119
- <div id="method-M000162" class="method-detail">
120
- <a name="M000162"></a>
119
+ <div id="method-M000166" class="method-detail">
120
+ <a name="M000166"></a>
121
121
 
122
122
  <div class="method-heading">
123
- <a href="#M000162" class="method-signature">
123
+ <a href="#M000166" class="method-signature">
124
124
  <span class="method-name">new</span><span class="method-args">(items)</span>
125
125
  </a>
126
126
  </div>
127
127
 
128
128
  <div class="method-description">
129
129
  <p><a class="source-toggle" href="#"
130
- onclick="toggleCode('M000162-source');return false;">[Source]</a></p>
131
- <div class="method-source-code" id="M000162-source">
130
+ onclick="toggleCode('M000166-source');return false;">[Source]</a></p>
131
+ <div class="method-source-code" id="M000166-source">
132
132
  <pre>
133
133
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 312</span>
134
134
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">items</span>)
@@ -142,19 +142,19 @@
142
142
 
143
143
  <h3 class="section-bar">Public Instance methods</h3>
144
144
 
145
- <div id="method-M000163" class="method-detail">
146
- <a name="M000163"></a>
145
+ <div id="method-M000167" class="method-detail">
146
+ <a name="M000167"></a>
147
147
 
148
148
  <div class="method-heading">
149
- <a href="#M000163" class="method-signature">
149
+ <a href="#M000167" class="method-signature">
150
150
  <span class="method-name">callback</span><span class="method-args">(symbol=nil, *args, &amp;block)</span>
151
151
  </a>
152
152
  </div>
153
153
 
154
154
  <div class="method-description">
155
155
  <p><a class="source-toggle" href="#"
156
- onclick="toggleCode('M000163-source');return false;">[Source]</a></p>
157
- <div class="method-source-code" id="M000163-source">
156
+ onclick="toggleCode('M000167-source');return false;">[Source]</a></p>
157
+ <div class="method-source-code" id="M000167-source">
158
158
  <pre>
159
159
  <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 328</span>
160
160
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">callback</span>(<span class="ruby-identifier">symbol</span>=<span class="ruby-keyword kw">nil</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
@@ -166,35 +166,43 @@
166
166
  </div>
167
167
  </div>
168
168
 
169
- <div id="method-M000164" class="method-detail">
170
- <a name="M000164"></a>
169
+ <div id="method-M000168" class="method-detail">
170
+ <a name="M000168"></a>
171
171
 
172
172
  <div class="method-heading">
173
- <a href="#M000164" class="method-signature">
173
+ <a href="#M000168" class="method-signature">
174
174
  <span class="method-name">with</span><span class="method-args">()</span>
175
175
  </a>
176
176
  </div>
177
177
 
178
178
  <div class="method-description">
179
179
  <p><a class="source-toggle" href="#"
180
- onclick="toggleCode('M000164-source');return false;">[Source]</a></p>
181
- <div class="method-source-code" id="M000164-source">
180
+ onclick="toggleCode('M000168-source');return false;">[Source]</a></p>
181
+ <div class="method-source-code" id="M000168-source">
182
182
  <pre>
183
- <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 347</span>
183
+ <span class="ruby-comment cmt"># File lib/wee/renderer/html/brushes.rb, line 351</span>
184
184
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">with</span>
185
185
  <span class="ruby-ivar">@labels</span> <span class="ruby-operator">||=</span> <span class="ruby-ivar">@items</span>.<span class="ruby-identifier">collect</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span> <span class="ruby-identifier">i</span>.<span class="ruby-identifier">to_s</span> }
186
- <span class="ruby-ivar">@selected</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>
186
+
187
+ <span class="ruby-identifier">is_multiple</span> = <span class="ruby-ivar">@attributes</span>.<span class="ruby-identifier">has_key?</span>(<span class="ruby-value str">'multiple'</span>)
187
188
 
188
189
  <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@callback</span>
189
190
  <span class="ruby-comment cmt"># A callback was specified. We have to wrap it inside a</span>
190
191
  <span class="ruby-comment cmt"># SelectListCallback object as we want to perform some </span>
191
192
  <span class="ruby-comment cmt"># additional actions.</span>
192
- <span class="ruby-identifier">__input_callback</span>(<span class="ruby-constant">SelectListCallback</span>.<span class="ruby-identifier">new</span>(<span class="ruby-ivar">@callback</span>, <span class="ruby-ivar">@items</span>, <span class="ruby-ivar">@attributes</span>.<span class="ruby-identifier">has_key?</span>(<span class="ruby-value str">'multiple'</span>)))
193
+ <span class="ruby-identifier">__input_callback</span>(<span class="ruby-constant">SelectListCallback</span>.<span class="ruby-identifier">new</span>(<span class="ruby-ivar">@callback</span>, <span class="ruby-ivar">@items</span>, <span class="ruby-identifier">is_multiple</span>))
193
194
  <span class="ruby-keyword kw">end</span>
194
195
 
195
196
  <span class="ruby-keyword kw">super</span> <span class="ruby-keyword kw">do</span>
196
- <span class="ruby-ivar">@items</span>.<span class="ruby-identifier">each_index</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span>
197
- <span class="ruby-ivar">@canvas</span>.<span class="ruby-identifier">option</span>.<span class="ruby-identifier">value</span>(<span class="ruby-identifier">i</span>).<span class="ruby-identifier">selected</span>(<span class="ruby-ivar">@selected</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-ivar">@items</span>[<span class="ruby-identifier">i</span>])).<span class="ruby-identifier">with</span>(<span class="ruby-ivar">@labels</span>[<span class="ruby-identifier">i</span>])
197
+ <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">is_multiple</span>
198
+ <span class="ruby-ivar">@selected</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>
199
+ <span class="ruby-ivar">@items</span>.<span class="ruby-identifier">each_index</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span>
200
+ <span class="ruby-ivar">@canvas</span>.<span class="ruby-identifier">option</span>.<span class="ruby-identifier">value</span>(<span class="ruby-identifier">i</span>).<span class="ruby-identifier">selected</span>(<span class="ruby-ivar">@selected</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-ivar">@items</span>[<span class="ruby-identifier">i</span>])).<span class="ruby-identifier">with</span>(<span class="ruby-ivar">@labels</span>[<span class="ruby-identifier">i</span>])
201
+ }
202
+ <span class="ruby-keyword kw">else</span>
203
+ <span class="ruby-ivar">@items</span>.<span class="ruby-identifier">each_index</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span>
204
+ <span class="ruby-ivar">@canvas</span>.<span class="ruby-identifier">option</span>.<span class="ruby-identifier">value</span>(<span class="ruby-identifier">i</span>).<span class="ruby-identifier">selected</span>(<span class="ruby-ivar">@selected</span> <span class="ruby-operator">==</span> <span class="ruby-ivar">@items</span>[<span class="ruby-identifier">i</span>]).<span class="ruby-identifier">with</span>(<span class="ruby-ivar">@labels</span>[<span class="ruby-identifier">i</span>])
205
+ }
198
206
  <span class="ruby-keyword kw">end</span>
199
207
  <span class="ruby-keyword kw">end</span>
200
208
  <span class="ruby-keyword kw">end</span>