|
| __construct (Config $config, PopupsContext $popupsContext, LoggerInterface $logger, UserOptionsManager $userOptionsManager) |
|
| onGetPreferences ( $user, &$prefs) |
| Add options to user Preferences page.
|
|
| onBeforePageDisplay ( $out, $skin) |
| Allows last minute changes to the output page, e.g.
|
|
| onResourceLoaderGetConfigVars (array &$vars, $skin, Config $config) |
| Hook handler for the ResourceLoaderStartUpModule that makes static configuration visible to the frontend.
|
|
| onMakeGlobalVariablesScript (&$vars, $out) |
| Hook handler publishing dynamic configuration that depends on the context, e.g.
|
|
◆ __construct()
Popups\PopupsHooks::__construct |
( |
Config | $config, |
|
|
PopupsContext | $popupsContext, |
|
|
LoggerInterface | $logger, |
|
|
UserOptionsManager | $userOptionsManager ) |
- Parameters
-
Config | $config | |
PopupsContext | $popupsContext | |
LoggerInterface | $logger | |
UserOptionsManager | $userOptionsManager | |
◆ getCustomPopupTypes()
static Popups\PopupsHooks::getCustomPopupTypes |
( |
| ) |
|
|
static |
Get custom Popups types registered by extensions.
- Returns
- array
◆ onBeforePageDisplay()
Popups\PopupsHooks::onBeforePageDisplay |
( |
| $out, |
|
|
| $skin ) |
Allows last minute changes to the output page, e.g.
adding of CSS or JavaScript by extensions.
- Parameters
-
OutputPage | $out | The Output page object |
Skin | $skin | Skin object that will be used to generate the page |
◆ onGetPreferences()
Popups\PopupsHooks::onGetPreferences |
( |
| $user, |
|
|
& | $prefs ) |
Add options to user Preferences page.
- Parameters
-
User | $user | User whose preferences are being modified |
array[] | &$prefs | Preferences description array, to be fed to a HTMLForm object |
◆ onMakeGlobalVariablesScript()
Popups\PopupsHooks::onMakeGlobalVariablesScript |
( |
& | $vars, |
|
|
| $out ) |
Hook handler publishing dynamic configuration that depends on the context, e.g.
the page or the users settings. These variables end in an inline <script> in the documents head.
Variables added:
- ‘wgPopupsConflictsWithNavPopupGadget’ - The server's notion of whether or not the user has enabled conflicting Navigational Popups Gadget.
- ‘wgPopupsConflictsWithRefTooltipsGadget’ - The server's notion of whether or not the user has enabled conflicting Reference Tooltips Gadget.
- Parameters
-
array | &$vars | variables to be added into the output of OutputPage::headElement |
IContextSource | $out | OutputPage instance calling the hook |
◆ onResourceLoaderGetConfigVars()
Popups\PopupsHooks::onResourceLoaderGetConfigVars |
( |
array & | $vars, |
|
|
| $skin, |
|
|
Config | $config ) |
Hook handler for the ResourceLoaderStartUpModule that makes static configuration visible to the frontend.
These variables end in the only "startup" ResourceLoader module that is loaded before all others.
Dynamic configuration that depends on the context needs to be published via the MakeGlobalVariablesScript hook.
- Parameters
-
array | &$vars | Array of variables to be added into the output of the startup module |
string | $skin | |
Config | $config | |
The documentation for this class was generated from the following file: