Index: trunk/extensions/TwitterLogin/TwitterLogin.i18n.php |
— | — | @@ -8,25 +8,17 @@ |
9 | 9 | * @author David Raison |
10 | 10 | */ |
11 | 11 | |
12 | | -$aliases = array(); |
13 | 12 | $messages = array(); |
14 | 13 | |
15 | 14 | /** English |
16 | 15 | * @author David Raison |
17 | 16 | */ |
18 | | -$aliases['en'] = array( |
19 | | - 'TwitterLogin' => array('TwitterLogin') |
20 | | -); |
21 | | - |
22 | | -/** English |
23 | | - * @author David Raison |
24 | | - */ |
25 | 17 | $messages['en'] = array( |
26 | 18 | 'twitterlogin' => 'Sign in using Twitter', |
27 | | - 'signuptwitter' => 'You can register to this wiki using your twitter account', |
28 | | - 'tietoaccount' => 'You are currently logged into this wiki as $1.<br/>You may sign in with Twitter to tie your twitter account to your existing mediawiki account.', |
| 19 | + 'twitterlogin-signup' => 'You can register to this wiki using your twitter account', |
| 20 | + 'twiterlogin-tietoaccount' => 'You are currently logged into this wiki as $1.<br/>You may sign in with Twitter to tie your twitter account to your existing mediawiki account.', |
29 | 21 | 'twitterlogin-desc' => 'Register and log in to a mediawiki using your twitter account', |
30 | | - 'alreadyloggedin' => 'You\'re already logged in.', |
31 | | - 'couldnotconnect' => 'Could not connect to Twitter. Refresh the page or try again later.' |
| 22 | + 'twitterlogin-alreadyloggedin' => 'You\'re already logged in.', |
| 23 | + 'twitterlogin-couldnotconnect' => 'Could not connect to Twitter. Refresh the page or try again later.' |
32 | 24 | ); |
33 | 25 | |
Index: trunk/extensions/TwitterLogin/TwitterLogin.php |
— | — | @@ -34,10 +34,11 @@ |
35 | 35 | $wgAutoloadClasses['TwitterSigninUI'] = dirname(__FILE__) . '/TwitterLogin.body.php'; |
36 | 36 | |
37 | 37 | $wgExtensionMessagesFiles['TwitterLogin'] = dirname(__FILE__) .'/TwitterLogin.i18n.php'; |
| 38 | +$wgExtensionAliasFiles['TwitterLogin'] = dirname(__FILE__) .'/TwitterLogin.alias.php'; |
| 39 | + |
38 | 40 | $wgSpecialPages['TwitterLogin'] = 'SpecialTwitterLogin'; |
39 | 41 | $wgSpecialPageGroups['TwitterLogin'] = 'login'; |
40 | 42 | |
41 | | -$wgHooks['LanguageGetMagic'][] = 'wfTwitterLoginLanguageGetMagic'; |
42 | 43 | $wgHooks['LoadExtensionSchemaUpdates'][] = 'efSetupTwitterLoginSchema'; |
43 | 44 | |
44 | 45 | $tsu = new TwitterSigninUI; |
— | — | @@ -47,11 +48,6 @@ |
48 | 49 | $wgHooks['UserLoadFromSession'][] = array($stl,'efTwitterAuth'); |
49 | 50 | $wgHooks['UserLogoutComplete'][] = array($stl,'efTwitterLogout'); |
50 | 51 | |
51 | | -function wfTwitterLoginLanguageGetMagic( &$magicWords, $langCode = 'en' ) { |
52 | | - $magicWords['twitterlogin'] = array( 0, 'twitterlogin' ); |
53 | | - return true; |
54 | | -} |
55 | | - |
56 | 52 | function efSetupTwitterLoginSchema() { |
57 | 53 | $updater->addExtensionUpdate( array( 'addTable', 'twitter_user', |
58 | 54 | dirname(__FILE__) . '/twitter_user.sql', true ) ); |
Index: trunk/extensions/TwitterLogin/SpecialTwitterLogin.php |
— | — | @@ -57,14 +57,14 @@ |
58 | 58 | $wgOut->setPagetitle("Twitter Login"); |
59 | 59 | |
60 | 60 | if ( !$wgUser->isLoggedIn() ) { |
61 | | - $wgOut->addWikiText( wfMsg( 'signuptwitter') ); |
| 61 | + $wgOut->addWikiText( wfMsg( 'twitterlogin-signup') ); |
62 | 62 | |
63 | 63 | $wgOut->addHTML( '<a href="' . $wgScriptPath . '/index.php/Special:TwitterLogin/redirect">' |
64 | 64 | .'<img src="' . $wgExtensionAssetsPath . '/TwitterLogin/' . |
65 | 65 | 'images/sign-in-with-twitter-d.png"/></a>' ); |
66 | 66 | } else { |
67 | | - //$wgOut->addWikiText( wfMsg( 'tietoaccount', $wgUser->getName() ) ); |
68 | | - $wgOut->addWikiText( wfMsg( 'alreadyloggedin' ) ); |
| 67 | + //$wgOut->addWikiText( wfMsg( 'twitterlogin-tietoaccount', $wgUser->getName() ) ); |
| 68 | + $wgOut->addWikiText( wfMsg( 'twitterlogin-alreadyloggedin' ) ); |
69 | 69 | } |
70 | 70 | return true; |
71 | 71 | } |
— | — | @@ -135,7 +135,7 @@ |
136 | 136 | header('Location: '. $url); |
137 | 137 | break; |
138 | 138 | default: |
139 | | - $wgOut->addWikiText( wfMsg( 'couldnotconnect' ) ); |
| 139 | + $wgOut->addWikiText( wfMsg( 'twitterlogin-couldnotconnect' ) ); |
140 | 140 | break; |
141 | 141 | } |
142 | 142 | } |
Index: trunk/extensions/TwitterLogin/TwitterLogin.alias.php |
— | — | @@ -0,0 +1,17 @@ |
| 2 | +<?php |
| 3 | +/** |
| 4 | + * @file TwitterLogin.alias.php |
| 5 | + * @ingroup TwitterLogin |
| 6 | + |
| 7 | + * @author David Raison |
| 8 | + */ |
| 9 | + |
| 10 | +$aliases = array(); |
| 11 | + |
| 12 | +/** English |
| 13 | + * @author David Raison |
| 14 | + */ |
| 15 | +$aliases['en'] = array( |
| 16 | + 'TwitterLogin' => array('TwitterLogin') |
| 17 | +); |
| 18 | + |
Property changes on: trunk/extensions/TwitterLogin/TwitterLogin.alias.php |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 19 | + native |