MDL-50937 jquery: remove instances of migrate plugin

This commit is contained in:
Dan Poltawski 2016-07-19 10:34:17 +01:00
parent 11caf2e2e1
commit 6851244452
2 changed files with 1 additions and 7 deletions

View file

@ -18,7 +18,6 @@
* This file describes jQuery plugins available in the Moodle * This file describes jQuery plugins available in the Moodle
* core component. These can be included in page using: * core component. These can be included in page using:
* $PAGE->requires->jquery(); * $PAGE->requires->jquery();
* $PAGE->requires->jquery_plugin('migrate');
* $PAGE->requires->jquery_plugin('ui'); * $PAGE->requires->jquery_plugin('ui');
* $PAGE->requires->jquery_plugin('ui-css'); * $PAGE->requires->jquery_plugin('ui-css');
* *

View file

@ -430,10 +430,6 @@ class page_requirements_manager {
* *
* NOTE: this should not be used in official Moodle distribution! * NOTE: this should not be used in official Moodle distribution!
* *
* We are going to bundle jQuery 1.9.x until we drop support
* all support for IE 6-8. Use $PAGE->requires->jquery_plugin('migrate')
* for code written for earlier jQuery versions.
*
* {@see http://docs.moodle.org/dev/jQuery} * {@see http://docs.moodle.org/dev/jQuery}
*/ */
public function jquery() { public function jquery() {
@ -450,7 +446,6 @@ class page_requirements_manager {
* *
* Included core plugins: * Included core plugins:
* - jQuery UI * - jQuery UI
* - jQuery Migrate (useful for code written for previous UI version)
* *
* Add-ons may include extra jQuery plugins in jquery/ directory, * Add-ons may include extra jQuery plugins in jquery/ directory,
* plugins.php file defines the mapping between plugin names and * plugins.php file defines the mapping between plugin names and
@ -497,7 +492,7 @@ class page_requirements_manager {
return false; return false;
} }
if ($component !== 'core' and in_array($plugin, array('jquery', 'ui', 'ui-css', 'migrate'))) { if ($component !== 'core' and in_array($plugin, array('jquery', 'ui', 'ui-css'))) {
debugging("jQuery plugin '$plugin' is included in Moodle core, other components can not use the same name.", DEBUG_DEVELOPER); debugging("jQuery plugin '$plugin' is included in Moodle core, other components can not use the same name.", DEBUG_DEVELOPER);
$component = 'core'; $component = 'core';
} else if ($component !== 'core' and strpos($component, '_') === false) { } else if ($component !== 'core' and strpos($component, '_') === false) {