Index: trunk/extensions/LiveTranslate/LiveTranslate.php |
— | — | @@ -25,7 +25,7 @@ |
26 | 26 | die( 'Not an entry point.' ); |
27 | 27 | } |
28 | 28 | |
29 | | -define( 'LiveTranslate_VERSION', '0.3' ); |
| 29 | +define( 'LiveTranslate_VERSION', '0.4 alpha' ); |
30 | 30 | |
31 | 31 | $wgExtensionCredits['other'][] = array( |
32 | 32 | 'path' => __FILE__, |
Index: trunk/extensions/LiveTranslate/LiveTranslate.hooks.php |
— | — | @@ -78,12 +78,11 @@ |
79 | 79 | && $article->exists() |
80 | 80 | && ( count( $egLiveTranslateLanguages ) > 1 || ( count( $egLiveTranslateLanguages ) == 1 && $egLiveTranslateLanguages[0] != $currentLang ) ) ) { |
81 | 81 | $wgOut->addHTML( |
82 | | - '<span class="notranslate" id="livetranslatespan">' . |
| 82 | + '<span class="notranslate" id="livetranslatespan" style="display:inline; float:right">' . |
83 | 83 | Html::rawElement( |
84 | 84 | 'div', |
85 | 85 | array( |
86 | | - 'id' => 'livetranslatediv', |
87 | | - 'style' => 'display:inline; float:right', |
| 86 | + 'id' => 'livetranslatediv' |
88 | 87 | ), |
89 | 88 | htmlspecialchars( wfMsg( 'livetranslate-translate-to' ) ) . |
90 | 89 | ' ' . |
— | — | @@ -101,13 +100,14 @@ |
102 | 101 | wfMsg( 'livetranslate-button-revert' ) |
103 | 102 | ) |
104 | 103 | ) . |
105 | | - '</span>' |
| 104 | + '<br /><div id="googlebranding" style="display:inline; float:right"></div></span>' |
106 | 105 | ); |
107 | 106 | |
108 | 107 | $wgOut->addScript( |
109 | 108 | Html::linkedScript( 'https://www.google.com/jsapi?key=' . htmlspecialchars( $egGoogleApiKey ) ) . |
110 | 109 | Html::inlineScript( |
111 | | - 'google.load("language", "1");' . |
| 110 | + 'google.load("language", "1"); |
| 111 | + google.setOnLoadCallback(function(){google.language.getBranding("googlebranding");});' . |
112 | 112 | 'var sourceLang = ' . json_encode( $currentLang ) . ';' |
113 | 113 | ) |
114 | 114 | ); |
Index: trunk/extensions/LiveTranslate/RELEASE-NOTES |
— | — | @@ -4,6 +4,12 @@ |
5 | 5 | Latest version of the release notes: http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/LiveTranslate/RELEASE-NOTES?view=co |
6 | 6 | |
7 | 7 | |
| 8 | +=== Version 0.4 === |
| 9 | +2011-01-xx |
| 10 | + |
| 11 | +* Added Google branding, which is required when using the Google Translate API. |
| 12 | +: https://code.google.com/apis/language/translate/v1/getting_started.html#getBranding |
| 13 | + |
8 | 14 | === Version 0.3 === |
9 | 15 | 2011-01-07 |
10 | 16 | |