MDL-15727 basic jQuery support
See http://docs.moodle.org/dev/jQuery for more details.
This commit is contained in:
@@ -481,6 +481,20 @@ class theme_config {
|
||||
$this->check_theme_arrows();
|
||||
}
|
||||
|
||||
/**
|
||||
* Let the theme initialise the page object (usually $PAGE).
|
||||
*
|
||||
* This may be used for example to request jQuery in add-ons.
|
||||
*
|
||||
* @param moodle_page $page
|
||||
*/
|
||||
public function init_page(moodle_page $page) {
|
||||
$themeinitfunction = 'theme_'.$this->name.'_page_init';
|
||||
if (function_exists($themeinitfunction)) {
|
||||
$themeinitfunction($page);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if arrows $THEME->rarrow, $THEME->larrow have been set (theme/-/config.php).
|
||||
* If not it applies sensible defaults.
|
||||
|
||||
Reference in New Issue
Block a user