Index: trunk/phase3/skins/common/wikibits.js |
— | — | @@ -114,7 +114,7 @@ |
115 | 115 | var oli = false; // the li where the oldid radio is checked |
116 | 116 | var hf = document.getElementById('pagehistory'); |
117 | 117 | if (!hf) |
118 | | - return; |
| 118 | + return true; |
119 | 119 | var lis = hf.getElementsByTagName('li'); |
120 | 120 | for (i=0;i<lis.length;i++) { |
121 | 121 | var inputs = historyRadios(lis[i]); |
— | — | @@ -125,7 +125,7 @@ |
126 | 126 | if (oli) { // it's the second checked radio |
127 | 127 | if (inputs[1].checked) { |
128 | 128 | oli.className = "selected"; |
129 | | - return false |
| 129 | + return false; |
130 | 130 | } |
131 | 131 | } else if (inputs[0].checked) { |
132 | 132 | return false; |
— | — | @@ -151,6 +151,7 @@ |
152 | 152 | } |
153 | 153 | } |
154 | 154 | } |
| 155 | + return true; |
155 | 156 | } |
156 | 157 | |
157 | 158 | // generate toc from prefs form, fold sections |
— | — | @@ -164,15 +165,15 @@ |
165 | 166 | return; // Occasional IE problem |
166 | 167 | prefform.className = prefform.className + 'jsprefs'; |
167 | 168 | var sections = new Array(); |
168 | | - children = prefform.childNodes; |
| 169 | + var children = prefform.childNodes; |
169 | 170 | var seci = 0; |
170 | | - for (i = 0; i < children.length; i++) { |
| 171 | + for (var i = 0; i < children.length; i++) { |
171 | 172 | if (children[i].nodeName.toLowerCase() == 'fieldset') { |
172 | 173 | children[i].id = 'prefsection-' + seci; |
173 | 174 | children[i].className = 'prefsection'; |
174 | 175 | if (is_opera || is_khtml) |
175 | 176 | children[i].className = 'prefsection operaprefsection'; |
176 | | - legends = children[i].getElementsByTagName('legend'); |
| 177 | + var legends = children[i].getElementsByTagName('legend'); |
177 | 178 | sections[seci] = new Object(); |
178 | 179 | legends[0].className = 'mainLegend'; |
179 | 180 | if (legends[0] && legends[0].firstChild.nodeValue) |
— | — | @@ -207,15 +208,15 @@ |
208 | 209 | } |
209 | 210 | |
210 | 211 | function uncoversection() { |
211 | | - oldsecid = this.parentNode.parentNode.selectedid; |
212 | | - newsec = document.getElementById(this.secid); |
| 212 | + var oldsecid = this.parentNode.parentNode.selectedid; |
| 213 | + var newsec = document.getElementById(this.secid); |
213 | 214 | if (oldsecid != this.secid) { |
214 | | - ul = document.getElementById('preftoc'); |
| 215 | + var ul = document.getElementById('preftoc'); |
215 | 216 | document.getElementById(oldsecid).style.display = 'none'; |
216 | 217 | newsec.style.display = 'block'; |
217 | 218 | ul.selectedid = this.secid; |
218 | | - lis = ul.getElementsByTagName('li'); |
219 | | - for (i = 0; i< lis.length; i++) { |
| 219 | + var lis = ul.getElementsByTagName('li'); |
| 220 | + for (var i = 0; i< lis.length; i++) { |
220 | 221 | lis[i].className = ''; |
221 | 222 | } |
222 | 223 | this.parentNode.className = 'selected'; |
— | — | @@ -239,7 +240,7 @@ |
240 | 241 | } |
241 | 242 | |
242 | 243 | function unhidetzbutton() { |
243 | | - tzb = document.getElementById('guesstimezonebutton') |
| 244 | + var tzb = document.getElementById('guesstimezonebutton'); |
244 | 245 | if (tzb) |
245 | 246 | tzb.style.display = 'inline'; |
246 | 247 | } |
— | — | @@ -348,6 +349,7 @@ |
349 | 350 | } |
350 | 351 | |
351 | 352 | parent.appendChild(image); |
| 353 | + return true; |
352 | 354 | } |
353 | 355 | |
354 | 356 | function mwSetupToolbar() { |
— | — | @@ -368,6 +370,7 @@ |
369 | 371 | for (var i in mwCustomEditButtons) { |
370 | 372 | mwInsertEditButton(toolbar, mwCustomEditButtons[i]); |
371 | 373 | } |
| 374 | + return true; |
372 | 375 | } |
373 | 376 | |
374 | 377 | function escapeQuotes(text) { |
— | — | @@ -742,4 +745,4 @@ |
743 | 746 | } |
744 | 747 | |
745 | 748 | hookEvent("load", allmessagesshow); |
746 | | -hookEvent("load", mwSetupToolbar); |
\ No newline at end of file |
| 749 | +hookEvent("load", mwSetupToolbar); |