OSDN Git Service

Fixed issue #209: High CPU usage in tortoiseproc.exe & Append text to edit ctrl
[tortoisegit/TortoiseGitJp.git] / contrib / drupal-modules / module / translator_credits.php
1 <!--break-->\r
2 <?php\r
3 //\r
4 // Drupal translator credits page\r
5 // loaded into "http://tortoisesvn.net/translator_credits"\r
6 //\r
7 // Copyright (C) 2004-2008 the TortoiseSVN team\r
8 // This file is distributed under the same license as TortoiseSVN\r
9 //\r
10 // $Author: steveking $\r
11 // $Date: 2008-07-25 02:17:50 +0800 (Fri, 25 Jul 2008) $\r
12 // $Rev: 13536 $\r
13 //\r
14 // Author: Lübbe Onken 2004-2008\r
15 //\r
16 \r
17 include("/var/www/vhosts/default/htdocs/modules/tortoisesvn/trans_data_trunk.inc");\r
18 include("/var/www/vhosts/default/htdocs/modules/tortoisesvn/trans_countries.inc");\r
19 include("/var/www/vhosts/default/htdocs/modules/tortoisesvn/tortoisevars.inc");\r
20 \r
21 function t_print_header($tsvn_var)\r
22 {\r
23 ?>\r
24 \r
25 <div class="content">\r
26 <p>\r
27 On this page we want to give credit to everyone who has contributed to the many translations we now have. I hope I haven't forgotten a translator... Thanks everybody!\r
28 </p>\r
29 \r
30 <?php\r
31 }\r
32 \r
33 function t_print_footer($tsvn_var)\r
34 {\r
35 ?>\r
36 \r
37 </div>\r
38 \r
39 <?php\r
40 }\r
41 \r
42 function t_print_table_header($name, $summary, $tsvn_var)\r
43 {\r
44 ?>\r
45 <h2><?php echo $summary ?></h2>\r
46 <div class="table">\r
47 <table class="translations" summary="<?php echo $summary ?>">\r
48 <tr>\r
49 <th class="lang">Nr.</th>\r
50 <th class="lang">Language</th>\r
51 <th class="lang">Translator(s)</th>\r
52 </tr>\r
53 <?php\r
54 }\r
55 \r
56 function t_print_table_footer()\r
57 {\r
58 ?>\r
59 </table>\r
60 </div>\r
61 <div style="clear:both">&nbsp;<br/></div>\r
62 <?php\r
63 }\r
64 \r
65 function t_print_content_stat($i, $postat, $poinfo, $tsvn_var)\r
66 {\r
67   $release=$tsvn_var['release'];\r
68   $build=$tsvn_var['build'];\r
69   $dlfile=$tsvn_var['url1']."LanguagePack_".$release.".".$build."-win32-".$poinfo[2].".msi".$tsvn_var['url2'];\r
70 \r
71   if ($poinfo[0] != '') {\r
72     $flagimg=$tsvn_var['flagpath']."$poinfo[2].png";\r
73 \r
74     echo "<td>$i</td>";\r
75     echo "<td class=\"lang\"><img src=\"$flagimg\" height=\"12\" width=\"18\" />&nbsp;<a href=\"$dlfile\">$poinfo[3]</a></td>";\r
76     echo "<td class=\"lang\">$poinfo[4]</td>";\r
77   }\r
78 }\r
79 \r
80 function t_print_all_stats($data, $countries, $tsvn_var)\r
81 {\r
82   $i=0;\r
83   foreach ($data as $key => $postat)\r
84     if ($postat[0] == 0) {\r
85       $i++;\r
86       echo "<tr>";\r
87       t_print_content_stat($i, $postat, $countries[$key], $tsvn_var);\r
88       echo "</tr>";\r
89     }\r
90 }\r
91 \r
92 //------------------------------------\r
93 //\r
94 // The program starts here\r
95 //\r
96 \r
97 t_print_header($tsvn_var);\r
98 \r
99 // Print Alphabetical statistics\r
100 t_print_table_header('alpha', 'Translator credits', $tsvn_var);\r
101 t_print_all_stats($TortoiseGUI, $countries, $tsvn_var);\r
102 t_print_table_footer();\r
103 \r
104 t_print_footer($tsvn_var);\r
105 ?>\r