2014-02-06 10:21:39 +00:00
|
|
|
<?php
|
|
|
|
/*
|
|
|
|
* This file is part of the MediaWiki extension Popups.
|
|
|
|
*
|
|
|
|
* Popups is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation, either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* Popups is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with Popups. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*
|
2014-02-07 06:08:59 +00:00
|
|
|
* This extension requires that the PageImages and TextExtracts
|
|
|
|
* extensions have also been installed.
|
|
|
|
*
|
2014-02-06 10:21:39 +00:00
|
|
|
* @file
|
|
|
|
* @ingroup extensions
|
|
|
|
*/
|
|
|
|
|
|
|
|
$wgExtensionCredits['other'][] = array(
|
|
|
|
'author' => array( 'Prateek Saxena', 'Yair Rand' ),
|
|
|
|
'descriptionmsg' => 'popups-desc',
|
|
|
|
'name' => 'Popups',
|
|
|
|
'path' => __FILE__,
|
|
|
|
'url' => 'https://www.mediawiki.org/wiki/Extension:Popups',
|
|
|
|
);
|
|
|
|
|
2014-02-10 09:18:19 +00:00
|
|
|
$localBasePath = dirname( __DIR__ ) . '/Popups';
|
|
|
|
$remoteExtPath = 'Popups';
|
|
|
|
|
2014-02-06 10:49:28 +00:00
|
|
|
$wgResourceModules = array_merge( $wgResourceModules, array(
|
|
|
|
"ext.popups" => array(
|
2014-02-07 07:35:34 +00:00
|
|
|
'scripts' => array(
|
|
|
|
'resources/ext.popups.core.js',
|
|
|
|
),
|
2014-02-06 11:11:29 +00:00
|
|
|
'styles' => array(
|
|
|
|
'resources/ext.popups.core.less',
|
|
|
|
'resources/ext.popups.animation.less',
|
|
|
|
),
|
2014-02-07 06:22:14 +00:00
|
|
|
'dependencies' => array(
|
|
|
|
'mediawiki.api',
|
|
|
|
),
|
2014-02-07 07:35:34 +00:00
|
|
|
'messages' => array(
|
|
|
|
'popups-edited-seconds',
|
|
|
|
'popups-edited-minutes',
|
|
|
|
'popups-edited-hours',
|
|
|
|
'popups-edited-days',
|
|
|
|
'popups-edited-years',
|
|
|
|
),
|
2014-02-06 10:49:28 +00:00
|
|
|
'remoteExtPath' => $remoteExtPath,
|
|
|
|
'localBasePath' => $localBasePath,
|
|
|
|
),
|
|
|
|
) );
|
|
|
|
|
|
|
|
$wgAutoloadClasses['PopupsHooks'] = __DIR__ . '/Popups.hooks.php';
|
2014-02-06 10:21:39 +00:00
|
|
|
$wgExtensionMessagesFiles['Popups'] = __DIR__ . '/Popups.i18n.php';
|
2014-02-07 11:52:40 +00:00
|
|
|
|
|
|
|
$wgHooks['GetBetaFeaturePreferences'][] = 'PopupsHooks::getPreferences';
|
2014-02-06 10:49:28 +00:00
|
|
|
$wgHooks['BeforePageDisplay'][] = 'PopupsHooks::onBeforePageDisplay';
|