Index: trunk/extensions/WikiAtHome/WikiAtHome.i18n.php |
— | — | @@ -28,13 +28,41 @@ |
29 | 29 | 'wah-long-error' => '(ffmpeg could not read this file: $1)', |
30 | 30 | |
31 | 31 | 'wah-transcode-working' => 'This video is being processed, please try again later', |
32 | | - 'wah-transcode-helpout' => 'The clip is $1 percent done. |
33 | | -You can help transcode this video by visiting [[Special:WikiAtHome|Wiki@Home]]', |
| 32 | + 'wah-transcode-helpout' => 'You can help transcode this video by visiting [[Special:WikiAtHome|Wiki@Home]]', |
34 | 33 | |
35 | 34 | 'wah-transcode-fail' => 'This file failed to transcode.', |
36 | 35 | |
37 | 36 | 'wah-javascript-off' => 'You must have JavaScript enabled to participate in Wiki@Home', |
38 | | - 'wah-loading' => 'loading Wiki@Home interface <blink>...</blink>' |
| 37 | + 'wah-loading' => 'loading Wiki@Home interface <blink>...</blink>', |
| 38 | + |
| 39 | + /* javascript msgs WikiAtHome.js */ |
| 40 | + "wah-menu-jobs" => "Jobs", |
| 41 | + "wah-menu-stats" => "Stats", |
| 42 | + "wah-menu-pref" => "Preferences", |
| 43 | + "wah-loading" => "loading Wiki@Home interface <blink>...</blink>", |
| 44 | + |
| 45 | + "wah-lookingforjob" => "Looking For a Job <blink>...</blink>", |
| 46 | + |
| 47 | + "wah-start-on-visit" => "Start up Wiki@Home any time I visit this site", |
| 48 | + "wah-jobs-while-away"=> "Only run jobs when I have been away from my browser for 20 minutes", |
| 49 | + |
| 50 | + "wah-nojobfound" => "No Job Found, Will retry in $1", |
| 51 | + |
| 52 | + "wah-notoken-login" => "Could not get a token. Are you logged in?", |
| 53 | + "wah-apioff" => "The wiki@home api appears to be off. Please Contact your wiki admin", |
| 54 | + |
| 55 | + "wah-doing-job" => "Job: <i>$1</i> on: <i>$2</i>", |
| 56 | + "wah-downloading" => "Downloading File <i>$1%</i> done", |
| 57 | + "wah-encoding" => "Encoding File <i>$1%</i> done", |
| 58 | + |
| 59 | + "wah-encoding-fail" => "Encoding Failed. Please reload this page or try back latter.", |
| 60 | + |
| 61 | + "wah-uploading" => "Uploading File <i>$1</i> done", |
| 62 | + "wah-uploadfail" => "Uploading Failed", |
| 63 | + "wah-doneuploading" => "Done Uploading. Thanks for your Contribution.", |
| 64 | + |
| 65 | + "wah-needs-firefogg"=> "To participate in wiki@home you need to install <a href=\"http://firefogg.org\">firefogg</a>", |
| 66 | + "wah-api-error" => "There has been an error with the api. Please try back later" |
39 | 67 | ); |
40 | 68 | |
41 | 69 | /** Message documentation (Message documentation) |
— | — | @@ -803,7 +831,7 @@ |
804 | 832 | 'wah-long-general' => '(mediafil, längd $2, $3)', |
805 | 833 | 'wah-long-error' => '(ffmpeg kunde inte läsa filen: $1)', |
806 | 834 | 'wah-transcode-working' => 'Videon bearbetas just ju, vänligen försök igen senare', |
807 | | - 'wah-transcode-helpout' => 'Filen är $1 procent klar. |
| 835 | + 'wah-transcode-helpout' => 'Filen är $1 procent klar. |
808 | 836 | Du kan hjälpa till att konvertera den här videon genom att besöka [[Special:WikiAtHome|Wiki@Home]]', |
809 | 837 | 'wah-transcode-fail' => 'Kunde inte konvertera den här filen.', |
810 | 838 | 'wah-javascript-off' => 'Du måste ha JavaScript aktiverat för att delta i Wiki@Home', |
Index: trunk/extensions/WikiAtHome/NonFreeVideoHandler.php |
— | — | @@ -308,10 +308,10 @@ |
309 | 309 | if( $this->percDone == -1){ |
310 | 310 | $waitHtml = wfMsgWikiHtml( 'wah-transcode-fail'); |
311 | 311 | }else{ |
312 | | - $waitHtml = wfMsgWikiHtml( 'wah-transcode-working' ) . '<br />'; |
| 312 | + $waitHtml = wfMsgWikiHtml( 'wah-transcode-working' ); |
313 | 313 | //check if we doing it ~at~ home then we know how far it is done: |
314 | 314 | if( $wgJobTypeConfig['transcode'][ 'assignAtHome' ] ){ |
315 | | - $waitHtml .= wfMsgExt('wah-transcode-helpout', array('parsemag'), $this->percDone); |
| 315 | + $waitHtml .= wfMsgWikiHtml('wah-transcode-helpout', $this->percDone); |
316 | 316 | } |
317 | 317 | } |
318 | 318 | |
Index: trunk/extensions/WikiAtHome/WahJobManager.php |
— | — | @@ -176,7 +176,7 @@ |
177 | 177 | $or = ''; |
178 | 178 | foreach($wgJobTypeConfig as $tKey=>$tSet){ |
179 | 179 | if( $tSet['assign' . $reqMode] ){ |
180 | | - $okyJobOrList = $or . ' ( set_job_type = ' . $dbr->addQuotes( $tKey ) . ' )'; |
| 180 | + $okyJobOrList .= $or . ' ( set_job_type = ' . $dbr->addQuotes( $tKey ) . ' )'; |
181 | 181 | $or = ' OR '; |
182 | 182 | } |
183 | 183 | } |
Index: trunk/extensions/WikiAtHome/WikiAtHome.js |
— | — | @@ -1,6 +1,5 @@ |
2 | 2 | //the core javascript file of the wiki@home extension |
3 | 3 | |
4 | | -// FIXME: needs localisation support. |
5 | 4 | //load msgs: |
6 | 5 | loadGM({ |
7 | 6 | "wah-menu-jobs" : "Jobs", |
— | — | @@ -24,12 +23,14 @@ |
25 | 24 | |
26 | 25 | "wah-encoding-fail" : "Encoding failed. Please reload this page or try back latter.", |
27 | 26 | |
28 | | - "wah-uploading" : "Uploading file <i>$i</i> done", |
| 27 | + "wah-uploading" : "Uploading file <i>$1</i> done", |
29 | 28 | "wah-uploadfail" : "Uploading failed", |
30 | 29 | "wah-doneuploading" : "Upload complete. Thank you for your contribution.", |
31 | 30 | |
32 | | - "wah-needs-firefogg": "To particate in Wiki@Home you need to install Firefogg." |
| 31 | + "wah-needs-firefogg": "To participate in Wiki@Home you need to install Firefogg." |
33 | 32 | |
| 33 | + "wah-api-error" : "There has been an error with the api. Please try back later" |
| 34 | + |
34 | 35 | }); |
35 | 36 | |
36 | 37 | |
— | — | @@ -188,8 +189,10 @@ |
189 | 190 | do_api_req({ |
190 | 191 | 'data' : reqObj |
191 | 192 | },function(data){ |
192 | | - //if we have a job update status to proccessing |
193 | | - if( data.wikiathome.nojobs ){ |
| 193 | + //if we have a job update status to processing |
| 194 | + if( data.error){ |
| 195 | + $j('#tab-jobs .wah-gen-status').html( gM('wah-api-error') ); |
| 196 | + }else if( data.wikiathome.nojobs ){ |
194 | 197 | _this.delayLookForJob(); |
195 | 198 | }else{ |
196 | 199 | //we do have job proccess it |
— | — | @@ -327,7 +330,7 @@ |
328 | 331 | } |
329 | 332 | |
330 | 333 | |
331 | | - //congradulate the user and issue new job request |
| 334 | + //congratulate the user and issue new job request |
332 | 335 | $j('#tab-jobs .prograss-status').html( |
333 | 336 | gM( 'wah-doneuploading' ) |
334 | 337 | ); |