MDL-32742: Remove right div swapping

Swapping div.right is not required, as toolboxes determine section id on each toggle event.
This commit is contained in:
Ruslan Kabalin 2012-05-09 13:50:03 +01:00
parent e16e2300c5
commit a7d0e1fdb5
2 changed files with 1 additions and 7 deletions

View File

@ -26,15 +26,12 @@ M.course.format.swap_sections = function(Y, node1, node2) {
var CSS = {
COURSECONTENT : 'course-content',
LEFT : 'left',
RIGHT : 'right',
SECTIONADDMENUS : 'section_add_menus',
SECTIONADDMENUS : 'section_add_menus'
};
var sectionlist = Y.Node.all('.'+CSS.COURSECONTENT+' '+M.course.format.get_section_selector(Y));
// Swap left block
sectionlist.item(node1).one('.'+CSS.LEFT).swap(sectionlist.item(node2).one('.'+CSS.LEFT));
// Swap right block
sectionlist.item(node1).one('.'+CSS.RIGHT).swap(sectionlist.item(node2).one('.'+CSS.RIGHT));
// Swap menus
sectionlist.item(node1).one('.'+CSS.SECTIONADDMENUS).swap(sectionlist.item(node2).one('.'+CSS.SECTIONADDMENUS));
}

View File

@ -26,7 +26,6 @@ M.course.format.swap_sections = function(Y, node1, node2) {
var CSS = {
COURSECONTENT : 'course-content',
LEFT : 'left',
RIGHT : 'right',
SECTIONADDMENUS : 'section_add_menus',
WEEKDATES: 'weekdates'
};
@ -34,8 +33,6 @@ M.course.format.swap_sections = function(Y, node1, node2) {
var sectionlist = Y.Node.all('.'+CSS.COURSECONTENT+' '+M.course.format.get_section_selector(Y));
// Swap left block
sectionlist.item(node1).one('.'+CSS.LEFT).swap(sectionlist.item(node2).one('.'+CSS.LEFT));
// Swap right block
sectionlist.item(node1).one('.'+CSS.RIGHT).swap(sectionlist.item(node2).one('.'+CSS.RIGHT));
// Swap menus
sectionlist.item(node1).one('.'+CSS.SECTIONADDMENUS).swap(sectionlist.item(node2).one('.'+CSS.SECTIONADDMENUS));
// Swap week dates